Mercurial > ~mikael > mcabber > hg
comparison mcabber/src/utf8.h @ 1571:481b60da99c9
Workaround for missing iswblank() on Solaris 8 & 9 (Sebastian Kayser)
author | Mikael Berthe <mikael@lilotux.net> |
---|---|
date | Sat, 11 Apr 2009 12:20:12 +0200 |
parents | 0f7e0346d9cb |
children |
comparison
equal
deleted
inserted
replaced
1570:3d4c85664dad | 1571:481b60da99c9 |
---|---|
15 # define get_char_width(c) 1 | 15 # define get_char_width(c) 1 |
16 #endif | 16 #endif |
17 | 17 |
18 #ifdef HAVE_WCTYPE_H | 18 #ifdef HAVE_WCTYPE_H |
19 # include <wctype.h> | 19 # include <wctype.h> |
20 | |
21 /* The following bit is a hack for Solaris 8&9 systems that don't have | |
22 * iswblank(). | |
23 * For now i made sure it comes after wctype.h so it doesn't create | |
24 * problems (wctype.h has calls to iswblank() before wctype() is declared). | |
25 * (Sebastian Kayser) | |
26 */ | |
27 # ifndef HAVE_ISWBLANK | |
28 # define iswblank(wc) iswctype(wc, wctype("blank")) | |
29 # endif | |
30 | |
20 #else | 31 #else |
21 # define iswblank(c) (c == ' ') | 32 # define iswblank(c) (c == ' ') |
22 # define iswalnum(c) isalnum(c) | 33 # define iswalnum(c) isalnum(c) |
23 # define iswprint(c) isprint(c) | 34 # define iswprint(c) isprint(c) |
24 # define towupper(c) toupper(c) | 35 # define towupper(c) toupper(c) |