|
ICU 73.2
73.2
|
00001 // © 2016 and later: Unicode, Inc. and others. 00002 // License & terms of use: http://www.unicode.org/copyright.html 00003 /* 00004 ******************************************************************************* 00005 * 00006 * Copyright (C) 1999-2011, International Business Machines 00007 * Corporation and others. All Rights Reserved. 00008 * 00009 ******************************************************************************* 00010 * file name: utf.h 00011 * encoding: UTF-8 00012 * tab size: 8 (not used) 00013 * indentation:4 00014 * 00015 * created on: 1999sep09 00016 * created by: Markus W. Scherer 00017 */ 00018 00116 #ifndef __UTF_H__ 00117 #define __UTF_H__ 00118 00119 #include "unicode/umachine.h" 00120 /* include the utfXX.h after the following definitions */ 00121 00122 /* single-code point definitions -------------------------------------------- */ 00123 00130 #define U_IS_UNICODE_NONCHAR(c) \ 00131 ((c)>=0xfdd0 && \ 00132 ((c)<=0xfdef || ((c)&0xfffe)==0xfffe) && (c)<=0x10ffff) 00133 00151 #define U_IS_UNICODE_CHAR(c) \ 00152 ((uint32_t)(c)<0xd800 || \ 00153 (0xdfff<(c) && (c)<=0x10ffff && !U_IS_UNICODE_NONCHAR(c))) 00154 00161 #define U_IS_BMP(c) ((uint32_t)(c)<=0xffff) 00162 00169 #define U_IS_SUPPLEMENTARY(c) ((uint32_t)((c)-0x10000)<=0xfffff) 00170 00177 #define U_IS_LEAD(c) (((c)&0xfffffc00)==0xd800) 00178 00185 #define U_IS_TRAIL(c) (((c)&0xfffffc00)==0xdc00) 00186 00193 #define U_IS_SURROGATE(c) (((c)&0xfffff800)==0xd800) 00194 00202 #define U_IS_SURROGATE_LEAD(c) (((c)&0x400)==0) 00203 00211 #define U_IS_SURROGATE_TRAIL(c) (((c)&0x400)!=0) 00212 00213 /* include the utfXX.h ------------------------------------------------------ */ 00214 00215 #if !U_NO_DEFAULT_INCLUDE_UTF_HEADERS 00216 00217 #include "unicode/utf8.h" 00218 #include "unicode/utf16.h" 00219 00220 /* utf_old.h contains deprecated, pre-ICU 2.4 definitions */ 00221 #include "unicode/utf_old.h" 00222 00223 #endif /* !U_NO_DEFAULT_INCLUDE_UTF_HEADERS */ 00224 00225 #endif /* __UTF_H__ */
1.7.6.1