Changeset 13055 in project for chicken


Ignore:
Timestamp:
01/22/09 01:53:56 (11 years ago)
Author:
Ivan Raikov
Message:

Backported fix to character-case operations.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • chicken/branches/chicken-3/chicken.h

    r11001 r13055  
    990990#define C_i_structurep(x, s)            C_mk_bool(!C_immediatep(x) && C_header_bits(x) == C_STRUCTURE_TYPE && C_block_item(x, 0) == (s))
    991991
    992 #define C_u_i_char_alphabeticp(x)       C_mk_bool(C_isalpha(C_character_code(x)))
    993 #define C_u_i_char_numericp(x)          C_mk_bool(C_isdigit(C_character_code(x)))
    994 #define C_u_i_char_whitespacep(x)       C_mk_bool(C_isspace(C_character_code(x)))
    995 #define C_u_i_char_upper_casep(x)       C_mk_bool(C_isupper(C_character_code(x)))
    996 #define C_u_i_char_lower_casep(x)       C_mk_bool(C_islower(C_character_code(x)))
    997 
    998 #define C_u_i_char_upcase(x)            C_make_character(C_toupper(C_character_code(x)))
    999 #define C_u_i_char_downcase(x)          C_make_character(C_tolower(C_character_code(x)))
     992#define C_u_i_char_alphabeticp(x)       C_mk_bool(C_isalpha(C_character_code(x) & 0xff))
     993#define C_u_i_char_numericp(x)          C_mk_bool(C_isdigit(C_character_code(x) & 0xff))
     994#define C_u_i_char_whitespacep(x)       C_mk_bool(C_isspace(C_character_code(x) & 0xff))
     995#define C_u_i_char_upper_casep(x)       C_mk_bool(C_isupper(C_character_code(x) & 0xff))
     996#define C_u_i_char_lower_casep(x)       C_mk_bool(C_islower(C_character_code(x) & 0xff))
     997
     998#define C_u_i_char_upcase(x)            C_make_character(C_toupper(C_character_code(x) & 0xff))
     999#define C_u_i_char_downcase(x)          C_make_character(C_tolower(C_character_code(x) & 0xff))
    10001000
    10011001#define C_i_list_ref(lst, i)            C_i_car(C_i_list_tail(lst, i))
Note: See TracChangeset for help on using the changeset viewer.