/* -*- buffer-read-only: t -*- * * regcharclass.h * * Copyright (C) 2007, by Larry Wall and others * * You may distribute under the terms of either the GNU General Public * License or the Artistic License, as specified in the README file. * * !!!!!!! DO NOT EDIT THIS FILE !!!!!!! * This file is built by Porting/regcharclass.pl. * (Generated at: Mon Apr 23 12:29:30 2007 GMT) * Any changes made here will be lost! */ /* LNBREAK: Line Break: \R "\x0D\x0A" # CRLF - Network (Windows) line ending 0x0A # LF | LINE FEED 0x0B # VT | VERTICAL TAB 0x0C # FF | FORM FEED 0x0D # CR | CARRIAGE RETURN 0x85 # NEL | NEXT LINE 0x2028 # LINE SEPARATOR 0x2029 # PARAGRAPH SEPARATOR */ /*** GENERATED CODE ***/ #define is_LNBREAK(s,is_utf8) \ ( ( ((U8*)s)[0]==13 ) ? \ ( ( ((U8*)s)[1]==10 ) ? 2 : 1 ) : \ ( (10<=((U8*)s)[0] && ((U8*)s)[0]<=12) ? 1 : \ ( (is_utf8) ? \ ( ( ((U8*)s)[0]==194 ) ? \ ( ( ((U8*)s)[1]==133 ) ? 2 : 0 ) : \ (((( ((U8*)s)[0]==226 ) && ( ((U8*)s)[1]==128 )) && ( ((U8*)s)[2]==168 || ((U8*)s)[2]==169 )) ? 3 : 0) ) :\ ( ((U8*)s)[0]==133 ) ) ) ) /*** GENERATED CODE ***/ #define is_LNBREAK_safe(s,e,is_utf8) \ ( ( (e) - (s) > 2 ) ? \ ( ( ((U8*)s)[0]==13 ) ? \ ( ( ((U8*)s)[1]==10 ) ? 2 : 1 ) : \ ( (10<=((U8*)s)[0] && ((U8*)s)[0]<=12) ? 1 : \ ( (is_utf8) ? \ ( ( ((U8*)s)[0]==194 ) ? \ ( ( ((U8*)s)[1]==133 ) ? 2 : 0 ) : \ (((( ((U8*)s)[0]==226 ) && ( ((U8*)s)[1]==128 )) && ( ((U8*)s)[2]==168 || ((U8*)s)[2]==169 )) ? 3 : 0) ) :\ ( ((U8*)s)[0]==133 ) ) ) ) : \ ( ( (e) - (s) > 1 ) ? \ ( ( ((U8*)s)[0]==13 ) ? \ ( ( ((U8*)s)[1]==10 ) ? 2 : 1 ) : \ ( (10<=((U8*)s)[0] && ((U8*)s)[0]<=12) ? 1 : \ ( (is_utf8) ? \ ((( ((U8*)s)[0]==194 ) && ( ((U8*)s)[1]==133 )) ? 2 : 0) : \ ( ((U8*)s)[0]==133 ) ) ) ) : \ ( ( (e) - (s) > 0 ) ? \ ( (10<=((U8*)s)[0] && ((U8*)s)[0]<=13) ? 1 : \ ( (!is_utf8) ? \ ( ((U8*)s)[0]==133 ) : 0 ) ) : 0 ) ) ) /*** GENERATED CODE ***/ #define is_LNBREAK_utf8(s) \ ( ( ((U8*)s)[0]==194 ) ? \ ( ( ((U8*)s)[1]==133 ) ? 2 : 0 ) : \ ( ( ((U8*)s)[0]==226 ) ? \ ((( ((U8*)s)[1]==128 ) && ( ((U8*)s)[2]==168 || ((U8*)s)[2]==169 )) ? 3 : 0) :\ ( ( ((U8*)s)[0]==13 ) ? \ ( ( ((U8*)s)[1]==10 ) ? 2 : 1 ) : \ (10<=((U8*)s)[0] && ((U8*)s)[0]<=12) ) ) ) /*** GENERATED CODE ***/ #define is_LNBREAK_utf8_safe(s,e) \ ( ( (e) - (s) > 2 ) ? \ ( ( ((U8*)s)[0]==194 ) ? \ ( ( ((U8*)s)[1]==133 ) ? 2 : 0 ) : \ ( ( ((U8*)s)[0]==226 ) ? \ ((( ((U8*)s)[1]==128 ) && ( ((U8*)s)[2]==168 || ((U8*)s)[2]==169 )) ? 3 : 0) :\ ( ( ((U8*)s)[0]==13 ) ? \ ( ( ((U8*)s)[1]==10 ) ? 2 : 1 ) : \ (10<=((U8*)s)[0] && ((U8*)s)[0]<=12) ) ) ) : \ ( ( (e) - (s) > 1 ) ? \ ( ( ((U8*)s)[0]==194 ) ? \ ( ( ((U8*)s)[1]==133 ) ? 2 : 0 ) : \ ( ( ((U8*)s)[0]==13 ) ? \ ( ( ((U8*)s)[1]==10 ) ? 2 : 1 ) : \ (10<=((U8*)s)[0] && ((U8*)s)[0]<=12) ) ) : \ ( ( (e) - (s) > 0 ) ? \ (10<=((U8*)s)[0] && ((U8*)s)[0]<=13) : 0 ) ) ) /*** GENERATED CODE ***/ #define is_LNBREAK_latin1(s) \ ( ( ((U8*)s)[0]==13 ) ? \ ( ( ((U8*)s)[1]==10 ) ? 2 : 1 ) : \ ( (10<=((U8*)s)[0] && ((U8*)s)[0]<=12) || ((U8*)s)[0]==133 ) ) /*** GENERATED CODE ***/ #define is_LNBREAK_latin1_safe(s,e) \ ( ( (e) - (s) > 1 ) ? \ ( ( ((U8*)s)[0]==13 ) ? \ ( ( ((U8*)s)[1]==10 ) ? 2 : 1 ) : \ ( (10<=((U8*)s)[0] && ((U8*)s)[0]<=12) || ((U8*)s)[0]==133 ) ) : \ ( ( (e) - (s) > 0 ) ? \ ( (10<=((U8*)s)[0] && ((U8*)s)[0]<=13) || ((U8*)s)[0]==133 ) : 0 ) ) /*** GENERATED CODE ***/ #define is_LNBREAK_cp(cp) \ ( (10<=cp && cp<=13) || ( cp > 13 && \ ( cp==133 || ( cp > 133 && \ ( cp==8232 || ( cp > 8232 && \ cp==8233 ) ) ) ) ) ) /* HORIZWS: Horizontal Whitespace: \h \H 0x09 # HT 0x20 # SPACE 0xa0 # NBSP 0x1680 # OGHAM SPACE MARK 0x180e # MONGOLIAN VOWEL SEPARATOR 0x2000 # EN QUAD 0x2001 # EM QUAD 0x2002 # EN SPACE 0x2003 # EM SPACE 0x2004 # THREE-PER-EM SPACE 0x2005 # FOUR-PER-EM SPACE 0x2006 # SIX-PER-EM SPACE 0x2007 # FIGURE SPACE 0x2008 # PUNCTUATION SPACE 0x2009 # THIN SPACE 0x200A # HAIR SPACE 0x202f # NARROW NO-BREAK SPACE 0x205f # MEDIUM MATHEMATICAL SPACE 0x3000 # IDEOGRAPHIC SPACE */ /*** GENERATED CODE ***/ #define is_HORIZWS(s,is_utf8) \ ( ( ((U8*)s)[0]==9 || ((U8*)s)[0]==32 ) ? 1 : \ ( (is_utf8) ? \ ( ( ((U8*)s)[0]==194 ) ? \ ( ( ((U8*)s)[1]==160 ) ? 2 : 0 ) : \ ( ( ((U8*)s)[0]==225 ) ? \ ( ( ((U8*)s)[1]==160 ) ? \ ( ( ((U8*)s)[2]==142 ) ? 3 : 0 ) : \ ((( ((U8*)s)[1]==154 ) && ( ((U8*)s)[2]==128 )) ? 3 : 0) ) : \ ( ( ((U8*)s)[0]==226 ) ? \ ( ( ((U8*)s)[1]==129 ) ? \ ( ( ((U8*)s)[2]==159 ) ? 3 : 0 ) : \ ((( ((U8*)s)[1]==128 ) && ( (128<=((U8*)s)[2] && ((U8*)s)[2]<=138) || ((U8*)s)[2]==175 )) ? 3 : 0) ) :\ (((( ((U8*)s)[0]==227 ) && ( ((U8*)s)[1]==128 )) && ( ((U8*)s)[2]==128 )) ? 3 : 0) ) ) ) :\ ( ((U8*)s)[0]==160 ) ) ) /*** GENERATED CODE ***/ #define is_HORIZWS_safe(s,e,is_utf8) \ ( ( (e) - (s) > 2 ) ? \ ( ( ((U8*)s)[0]==9 || ((U8*)s)[0]==32 ) ? 1 : \ ( (is_utf8) ? \ ( ( ((U8*)s)[0]==194 ) ? \ ( ( ((U8*)s)[1]==160 ) ? 2 : 0 ) : \ ( ( ((U8*)s)[0]==225 ) ? \ ( ( ((U8*)s)[1]==160 ) ? \ ( ( ((U8*)s)[2]==142 ) ? 3 : 0 ) : \ ((( ((U8*)s)[1]==154 ) && ( ((U8*)s)[2]==128 )) ? 3 : 0) ) : \ ( ( ((U8*)s)[0]==226 ) ? \ ( ( ((U8*)s)[1]==129 ) ? \ ( ( ((U8*)s)[2]==159 ) ? 3 : 0 ) : \ ((( ((U8*)s)[1]==128 ) && ( (128<=((U8*)s)[2] && ((U8*)s)[2]<=138) || ((U8*)s)[2]==175 )) ? 3 : 0) ) :\ (((( ((U8*)s)[0]==227 ) && ( ((U8*)s)[1]==128 )) && ( ((U8*)s)[2]==128 )) ? 3 : 0) ) ) ) :\ ( ((U8*)s)[0]==160 ) ) ) : \ ( ( (e) - (s) > 1 ) ? \ ( ( ((U8*)s)[0]==9 || ((U8*)s)[0]==32 ) ? 1 : \ ( (is_utf8) ? \ ((( ((U8*)s)[0]==194 ) && ( ((U8*)s)[1]==160 )) ? 2 : 0) : \ ( ((U8*)s)[0]==160 ) ) ) : \ ( ( (e) - (s) > 0 ) ? \ ( ( ((U8*)s)[0]==9 || ((U8*)s)[0]==32 ) ? 1 : \ ( (!is_utf8) ? \ ( ((U8*)s)[0]==160 ) : 0 ) ) : 0 ) ) ) /*** GENERATED CODE ***/ #define is_HORIZWS_utf8(s) \ ( ( ((U8*)s)[0]==194 ) ? \ ( ( ((U8*)s)[1]==160 ) ? 2 : 0 ) : \ ( ( ((U8*)s)[0]==225 ) ? \ ( ( ((U8*)s)[1]==160 ) ? \ ( ( ((U8*)s)[2]==142 ) ? 3 : 0 ) : \ ((( ((U8*)s)[1]==154 ) && ( ((U8*)s)[2]==128 )) ? 3 : 0) ) : \ ( ( ((U8*)s)[0]==226 ) ? \ ( ( ((U8*)s)[1]==129 ) ? \ ( ( ((U8*)s)[2]==159 ) ? 3 : 0 ) : \ ((( ((U8*)s)[1]==128 ) && ( (128<=((U8*)s)[2] && ((U8*)s)[2]<=138) || ((U8*)s)[2]==175 )) ? 3 : 0) ) :\ ( ( ((U8*)s)[0]==227 ) ? \ ((( ((U8*)s)[1]==128 ) && ( ((U8*)s)[2]==128 )) ? 3 : 0) : \ ( ((U8*)s)[0]==9 || ((U8*)s)[0]==32 ) ) ) ) ) /*** GENERATED CODE ***/ #define is_HORIZWS_utf8_safe(s,e) \ ( ( (e) - (s) > 2 ) ? \ ( ( ((U8*)s)[0]==194 ) ? \ ( ( ((U8*)s)[1]==160 ) ? 2 : 0 ) : \ ( ( ((U8*)s)[0]==225 ) ? \ ( ( ((U8*)s)[1]==160 ) ? \ ( ( ((U8*)s)[2]==142 ) ? 3 : 0 ) : \ ((( ((U8*)s)[1]==154 ) && ( ((U8*)s)[2]==128 )) ? 3 : 0) ) : \ ( ( ((U8*)s)[0]==226 ) ? \ ( ( ((U8*)s)[1]==129 ) ? \ ( ( ((U8*)s)[2]==159 ) ? 3 : 0 ) : \ ((( ((U8*)s)[1]==128 ) && ( (128<=((U8*)s)[2] && ((U8*)s)[2]<=138) || ((U8*)s)[2]==175 )) ? 3 : 0) ) :\ ( ( ((U8*)s)[0]==227 ) ? \ ((( ((U8*)s)[1]==128 ) && ( ((U8*)s)[2]==128 )) ? 3 : 0) : \ ( ((U8*)s)[0]==9 || ((U8*)s)[0]==32 ) ) ) ) ) : \ ( ( (e) - (s) > 1 ) ? \ ( ( ((U8*)s)[0]==194 ) ? \ ( ( ((U8*)s)[1]==160 ) ? 2 : 0 ) : \ ( ((U8*)s)[0]==9 || ((U8*)s)[0]==32 ) ) : \ ( ( (e) - (s) > 0 ) ? \ ( ((U8*)s)[0]==9 || ((U8*)s)[0]==32 ) : 0 ) ) ) /*** GENERATED CODE ***/ #define is_HORIZWS_latin1(s) \ ( ((U8*)s)[0]==9 || ((U8*)s)[0]==32 || ((U8*)s)[0]==160 ) /*** GENERATED CODE ***/ #define is_HORIZWS_latin1_safe(s,e) \ ( ( (e) - (s) > 0 ) ? \ ( ((U8*)s)[0]==9 || ((U8*)s)[0]==32 || ((U8*)s)[0]==160 ) : 0 ) /*** GENERATED CODE ***/ #define is_HORIZWS_cp(cp) \ ( cp==9 || ( cp > 9 && \ ( cp==32 || ( cp > 32 && \ ( cp==160 || ( cp > 160 && \ ( cp==5760 || ( cp > 5760 && \ ( cp==6158 || ( cp > 6158 && \ ( (8192<=cp && cp<=8202) || ( cp > 8202 && \ ( cp==8239 || ( cp > 8239 && \ ( cp==8287 || ( cp > 8287 && \ cp==12288 ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) /* VERTWS: Vertical Whitespace: \v \V 0x0A # LF 0x0B # VT 0x0C # FF 0x0D # CR 0x85 # NEL 0x2028 # LINE SEPARATOR 0x2029 # PARAGRAPH SEPARATOR */ /*** GENERATED CODE ***/ #define is_VERTWS(s,is_utf8) \ ( (10<=((U8*)s)[0] && ((U8*)s)[0]<=13) ? 1 : \ ( (is_utf8) ? \ ( ( ((U8*)s)[0]==194 ) ? \ ( ( ((U8*)s)[1]==133 ) ? 2 : 0 ) : \ (((( ((U8*)s)[0]==226 ) && ( ((U8*)s)[1]==128 )) && ( ((U8*)s)[2]==168 || ((U8*)s)[2]==169 )) ? 3 : 0) ) :\ ( ((U8*)s)[0]==133 ) ) ) /*** GENERATED CODE ***/ #define is_VERTWS_safe(s,e,is_utf8) \ ( ( (e) - (s) > 2 ) ? \ ( (10<=((U8*)s)[0] && ((U8*)s)[0]<=13) ? 1 : \ ( (is_utf8) ? \ ( ( ((U8*)s)[0]==194 ) ? \ ( ( ((U8*)s)[1]==133 ) ? 2 : 0 ) : \ (((( ((U8*)s)[0]==226 ) && ( ((U8*)s)[1]==128 )) && ( ((U8*)s)[2]==168 || ((U8*)s)[2]==169 )) ? 3 : 0) ) :\ ( ((U8*)s)[0]==133 ) ) ) : \ ( ( (e) - (s) > 1 ) ? \ ( (10<=((U8*)s)[0] && ((U8*)s)[0]<=13) ? 1 : \ ( (is_utf8) ? \ ((( ((U8*)s)[0]==194 ) && ( ((U8*)s)[1]==133 )) ? 2 : 0) : \ ( ((U8*)s)[0]==133 ) ) ) : \ ( ( (e) - (s) > 0 ) ? \ ( (10<=((U8*)s)[0] && ((U8*)s)[0]<=13) ? 1 : \ ( (!is_utf8) ? \ ( ((U8*)s)[0]==133 ) : 0 ) ) : 0 ) ) ) /*** GENERATED CODE ***/ #define is_VERTWS_utf8(s) \ ( ( ((U8*)s)[0]==194 ) ? \ ( ( ((U8*)s)[1]==133 ) ? 2 : 0 ) : \ ( ( ((U8*)s)[0]==226 ) ? \ ((( ((U8*)s)[1]==128 ) && ( ((U8*)s)[2]==168 || ((U8*)s)[2]==169 )) ? 3 : 0) :\ (10<=((U8*)s)[0] && ((U8*)s)[0]<=13) ) ) /*** GENERATED CODE ***/ #define is_VERTWS_utf8_safe(s,e) \ ( ( (e) - (s) > 2 ) ? \ ( ( ((U8*)s)[0]==194 ) ? \ ( ( ((U8*)s)[1]==133 ) ? 2 : 0 ) : \ ( ( ((U8*)s)[0]==226 ) ? \ ((( ((U8*)s)[1]==128 ) && ( ((U8*)s)[2]==168 || ((U8*)s)[2]==169 )) ? 3 : 0) :\ (10<=((U8*)s)[0] && ((U8*)s)[0]<=13) ) ) : \ ( ( (e) - (s) > 1 ) ? \ ( ( ((U8*)s)[0]==194 ) ? \ ( ( ((U8*)s)[1]==133 ) ? 2 : 0 ) : \ (10<=((U8*)s)[0] && ((U8*)s)[0]<=13) ) : \ ( ( (e) - (s) > 0 ) ? \ (10<=((U8*)s)[0] && ((U8*)s)[0]<=13) : 0 ) ) ) /*** GENERATED CODE ***/ #define is_VERTWS_latin1(s) \ ( (10<=((U8*)s)[0] && ((U8*)s)[0]<=13) || ((U8*)s)[0]==133 ) /*** GENERATED CODE ***/ #define is_VERTWS_latin1_safe(s,e) \ ( ( (e) - (s) > 0 ) ? \ ( (10<=((U8*)s)[0] && ((U8*)s)[0]<=13) || ((U8*)s)[0]==133 ) : 0 ) /*** GENERATED CODE ***/ #define is_VERTWS_cp(cp) \ ( (10<=cp && cp<=13) || ( cp > 13 && \ ( cp==133 || ( cp > 133 && \ ( cp==8232 || ( cp > 8232 && \ cp==8233 ) ) ) ) ) ) /* ex: set ro: */