1
0
Fork 0
forked from len0rd/rockbox

Don't reinvent ctype.h functions

Remove ctype.h functions in text_editor and rockboy,
fix #define name clash in mpegplayer.

Change-Id: Icb40cf45e27b793c62cb095197757a27f508f344
This commit is contained in:
Nils Wallménius 2012-05-07 18:27:46 +02:00
parent 3f61caa0cd
commit 7803f31c53
4 changed files with 19 additions and 26 deletions

View file

@ -52,11 +52,6 @@ void dynamic_recompile (struct dynarec_block *newblock);
#define IBSS_ATTR
#endif
/* libc functions */
#define isdigit(c) ((c) >= '0' && (c) <= '9')
#define isalpha(c) (((c) >= 'a' && (c) <= 'z') || ((c) >= 'A' && ((c) <= 'Z')))
#define isalnum(c) (isdigit(c) || (isalpha(c)))
/* only 1 fixed argument for open, since variadic macros don't except empty
* variable parameters */
#define open(a, ...) rb->open((a), __VA_ARGS__)
@ -79,7 +74,6 @@ void dynamic_recompile (struct dynarec_block *newblock);
#define strcat(a,b) rb->strcat((a),(b))
#define snprintf(...) rb->snprintf(__VA_ARGS__)
#define fdprintf(...) rb->fdprintf(__VA_ARGS__)
#define tolower(_A_) (isupper(_A_) ? (_A_ - 'A' + 'a') : _A_)
/* Using #define isn't enough with GCC 4.0.1 */
void* memcpy(void* dst, const void* src, size_t size) ICODE_ATTR;