This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
regen/regcharclass_multi_char_folds.pl: Don't do unnecessary work
[perl5.git] / regcharclass.h
CommitLineData
8770da0e 1/* -*- buffer-read-only: t -*-
58fbde93
RGS
2 *
3 * regcharclass.h
4 *
2eee27d7 5 * Copyright (C) 2007, 2011 by Larry Wall and others
58fbde93
RGS
6 *
7 * You may distribute under the terms of either the GNU General Public
8 * License or the Artistic License, as specified in the README file.
9 *
10 * !!!!!!! DO NOT EDIT THIS FILE !!!!!!!
98e310af 11 * This file is built by regen/regcharclass.pl.
58fbde93 12 * Any changes made here will be lost!
212b6c86
KW
13 * WARNING: These macros are for internal Perl core use only, and may be
14 * changed or removed without notice.
58fbde93 15 */
12b72891 16
d10c72f2
KW
17
18#ifndef H_REGCHARCLASS /* Guard against nested #includes */
19#define H_REGCHARCLASS 1
20
12b72891
RGS
21/*
22 LNBREAK: Line Break: \R
23
58fbde93 24 "\x0D\x0A" # CRLF - Network (Windows) line ending
05b688d9 25 \p{VertSpace}
12b72891
RGS
26*/
27/*** GENERATED CODE ***/
12b72891 28#define is_LNBREAK_safe(s,e,is_utf8) \
e64b1bd1 29( ((e)-(s) > 2) ? \
c4c8e615
KW
30 ( ( 0x0A <= NATIVE_TO_LATIN1(((U8*)s)[0]) && NATIVE_TO_LATIN1(((U8*)s)[0]) <= 0x0C ) ? 1\
31 : ( 0x0D == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
32 ( ( 0x0A == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ? 2 : 1 ) \
e64b1bd1 33 : ( is_utf8 ) ? \
c4c8e615
KW
34 ( ( 0xC2 == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
35 ( ( 0x85 == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ? 2 : 0 ) \
36 : ( ( ( 0xE2 == NATIVE_TO_LATIN1(((U8*)s)[0]) ) && ( 0x80 == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ) && ( ( NATIVE_TO_LATIN1(((U8*)s)[2]) & 0xFE ) == 0xA8 ) ) ? 3 : 0 )\
37 : ( 0x85 == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ) \
e64b1bd1 38: ((e)-(s) > 1) ? \
c4c8e615
KW
39 ( ( 0x0A <= NATIVE_TO_LATIN1(((U8*)s)[0]) && NATIVE_TO_LATIN1(((U8*)s)[0]) <= 0x0C ) ? 1\
40 : ( 0x0D == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
41 ( ( 0x0A == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ? 2 : 1 ) \
e64b1bd1 42 : ( is_utf8 ) ? \
c4c8e615
KW
43 ( ( ( 0xC2 == NATIVE_TO_LATIN1(((U8*)s)[0]) ) && ( 0x85 == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ) ? 2 : 0 )\
44 : ( 0x85 == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ) \
e64b1bd1 45: ((e)-(s) > 0) ? \
c4c8e615 46 ( ( 0x0A <= NATIVE_TO_LATIN1(((U8*)s)[0]) && NATIVE_TO_LATIN1(((U8*)s)[0]) <= 0x0D ) ? 1\
e64b1bd1 47 : ( !( is_utf8 ) ) ? \
c4c8e615 48 ( 0x85 == NATIVE_TO_LATIN1(((U8*)s)[0]) ) \
e64b1bd1
YO
49 : 0 ) \
50: 0 )
e1d1eefb 51
12b72891 52/*** GENERATED CODE ***/
12b72891 53#define is_LNBREAK_utf8_safe(s,e) \
e64b1bd1 54( ((e)-(s) > 2) ? \
c4c8e615
KW
55 ( ( 0x0A <= NATIVE_TO_LATIN1(((U8*)s)[0]) && NATIVE_TO_LATIN1(((U8*)s)[0]) <= 0x0C ) ? 1\
56 : ( 0x0D == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
57 ( ( 0x0A == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ? 2 : 1 ) \
58 : ( 0xC2 == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
59 ( ( 0x85 == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ? 2 : 0 ) \
60 : ( ( ( 0xE2 == NATIVE_TO_LATIN1(((U8*)s)[0]) ) && ( 0x80 == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ) && ( ( NATIVE_TO_LATIN1(((U8*)s)[2]) & 0xFE ) == 0xA8 ) ) ? 3 : 0 )\
e64b1bd1 61: ((e)-(s) > 1) ? \
c4c8e615
KW
62 ( ( 0x0A <= NATIVE_TO_LATIN1(((U8*)s)[0]) && NATIVE_TO_LATIN1(((U8*)s)[0]) <= 0x0C ) ? 1\
63 : ( 0x0D == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
64 ( ( 0x0A == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ? 2 : 1 ) \
65 : ( ( 0xC2 == NATIVE_TO_LATIN1(((U8*)s)[0]) ) && ( 0x85 == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ) ? 2 : 0 )\
e64b1bd1 66: ((e)-(s) > 0) ? \
c4c8e615 67 ( 0x0A <= NATIVE_TO_LATIN1(((U8*)s)[0]) && NATIVE_TO_LATIN1(((U8*)s)[0]) <= 0x0D )\
e64b1bd1 68: 0 )
e1d1eefb 69
12b72891 70/*** GENERATED CODE ***/
12b72891 71#define is_LNBREAK_latin1_safe(s,e) \
e64b1bd1 72( ((e)-(s) > 1) ? \
c4c8e615
KW
73 ( ( ( 0x0A <= NATIVE_TO_LATIN1(((U8*)s)[0]) && NATIVE_TO_LATIN1(((U8*)s)[0]) <= 0x0C ) || 0x85 == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? 1\
74 : ( 0x0D == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
75 ( ( 0x0A == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ? 2 : 1 ) \
9a3182e9 76 : 0 ) \
e64b1bd1 77: ((e)-(s) > 0) ? \
c4c8e615 78 ( ( 0x0A <= NATIVE_TO_LATIN1(((U8*)s)[0]) && NATIVE_TO_LATIN1(((U8*)s)[0]) <= 0x0D ) || 0x85 == NATIVE_TO_LATIN1(((U8*)s)[0]) )\
e64b1bd1 79: 0 )
12b72891
RGS
80
81/*
82 HORIZWS: Horizontal Whitespace: \h \H
83
05b688d9 84 \p{HorizSpace}
12b72891
RGS
85*/
86/*** GENERATED CODE ***/
2cafb56b 87#define is_HORIZWS_high(s) \
c4c8e615 88( ( 0xE1 == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
a9c9e371 89 ( ( ( 0x9A == NATIVE_TO_LATIN1(((U8*)s)[1]) ) && ( 0x80 == NATIVE_TO_LATIN1(((U8*)s)[2]) ) ) ? 3 : 0 )\
c4c8e615
KW
90: ( 0xE2 == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
91 ( ( 0x80 == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ? \
92 ( ( ( NATIVE_TO_LATIN1(((U8*)s)[2]) <= 0x8A ) || 0xAF == NATIVE_TO_LATIN1(((U8*)s)[2]) ) ? 3 : 0 )\
93 : ( ( 0x81 == NATIVE_TO_LATIN1(((U8*)s)[1]) ) && ( 0x9F == NATIVE_TO_LATIN1(((U8*)s)[2]) ) ) ? 3 : 0 )\
94: ( ( ( 0xE3 == NATIVE_TO_LATIN1(((U8*)s)[0]) ) && ( 0x80 == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ) && ( 0x80 == NATIVE_TO_LATIN1(((U8*)s)[2]) ) ) ? 3 : 0 )
2cafb56b
KW
95
96/*** GENERATED CODE ***/
2cafb56b 97#define is_HORIZWS_cp_high(cp) \
c4c8e615 98( 0x1680 == NATIVE_TO_UNI(cp) || ( 0x1680 < NATIVE_TO_UNI(cp) && \
c4c8e615
KW
99( ( 0x2000 <= NATIVE_TO_UNI(cp) && NATIVE_TO_UNI(cp) <= 0x200A ) || ( 0x200A < NATIVE_TO_UNI(cp) &&\
100( 0x202F == NATIVE_TO_UNI(cp) || ( 0x202F < NATIVE_TO_UNI(cp) && \
a9c9e371 101( 0x205F == NATIVE_TO_UNI(cp) || 0x3000 == NATIVE_TO_UNI(cp) ) ) ) ) ) ) )
2cafb56b 102
12b72891
RGS
103/*
104 VERTWS: Vertical Whitespace: \v \V
e1d1eefb 105
05b688d9 106 \p{VertSpace}
12b72891
RGS
107*/
108/*** GENERATED CODE ***/
840f8e92 109#define is_VERTWS_high(s) \
c4c8e615 110( ( ( ( 0xE2 == NATIVE_TO_LATIN1(((U8*)s)[0]) ) && ( 0x80 == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ) && ( ( NATIVE_TO_LATIN1(((U8*)s)[2]) & 0xFE ) == 0xA8 ) ) ? 3 : 0 )
840f8e92
KW
111
112/*** GENERATED CODE ***/
840f8e92 113#define is_VERTWS_cp_high(cp) \
c4c8e615 114( 0x2028 == NATIVE_TO_UNI(cp) || 0x2029 == NATIVE_TO_UNI(cp) )
840f8e92 115
612ead59 116/*
4ac6419d
KW
117 XDIGIT: Hexadecimal digits
118
119 \p{XDigit}
120*/
121/*** GENERATED CODE ***/
4ac6419d 122#define is_XDIGIT_high(s) \
c4c8e615
KW
123( ( 0xEF == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
124 ( ( 0xBC == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ? \
125 ( ( ( 0x90 <= NATIVE_TO_LATIN1(((U8*)s)[2]) && NATIVE_TO_LATIN1(((U8*)s)[2]) <= 0x99 ) || ( 0xA1 <= NATIVE_TO_LATIN1(((U8*)s)[2]) && NATIVE_TO_LATIN1(((U8*)s)[2]) <= 0xA6 ) ) ? 3 : 0 )\
126 : ( ( 0xBD == NATIVE_TO_LATIN1(((U8*)s)[1]) ) && ( 0x81 <= NATIVE_TO_LATIN1(((U8*)s)[2]) && NATIVE_TO_LATIN1(((U8*)s)[2]) <= 0x86 ) ) ? 3 : 0 )\
4ac6419d
KW
127: 0 )
128
129/*** GENERATED CODE ***/
130#define is_XDIGIT_cp_high(cp) \
c4c8e615
KW
131( ( 0xFF10 <= NATIVE_TO_UNI(cp) && NATIVE_TO_UNI(cp) <= 0xFF19 ) || ( 0xFF19 < NATIVE_TO_UNI(cp) &&\
132( ( 0xFF21 <= NATIVE_TO_UNI(cp) && NATIVE_TO_UNI(cp) <= 0xFF26 ) || ( 0xFF41 <= NATIVE_TO_UNI(cp) && NATIVE_TO_UNI(cp) <= 0xFF46 ) ) ) )
4ac6419d
KW
133
134/*
bedac28b
KW
135 XPERLSPACE: \p{XPerlSpace}
136
137 \p{XPerlSpace}
138*/
139/*** GENERATED CODE ***/
bedac28b 140#define is_XPERLSPACE_high(s) \
c4c8e615 141( ( 0xE1 == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
a9c9e371 142 ( ( ( 0x9A == NATIVE_TO_LATIN1(((U8*)s)[1]) ) && ( 0x80 == NATIVE_TO_LATIN1(((U8*)s)[2]) ) ) ? 3 : 0 )\
c4c8e615
KW
143: ( 0xE2 == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
144 ( ( 0x80 == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ? \
145 ( ( ( NATIVE_TO_LATIN1(((U8*)s)[2]) <= 0x8A ) || ( NATIVE_TO_LATIN1(((U8*)s)[2]) & 0xFE ) == 0xA8 || 0xAF == NATIVE_TO_LATIN1(((U8*)s)[2]) ) ? 3 : 0 )\
146 : ( ( 0x81 == NATIVE_TO_LATIN1(((U8*)s)[1]) ) && ( 0x9F == NATIVE_TO_LATIN1(((U8*)s)[2]) ) ) ? 3 : 0 )\
147: ( ( ( 0xE3 == NATIVE_TO_LATIN1(((U8*)s)[0]) ) && ( 0x80 == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ) && ( 0x80 == NATIVE_TO_LATIN1(((U8*)s)[2]) ) ) ? 3 : 0 )
bedac28b
KW
148
149/*** GENERATED CODE ***/
150#define is_XPERLSPACE_cp_high(cp) \
c4c8e615 151( 0x1680 == NATIVE_TO_UNI(cp) || ( 0x1680 < NATIVE_TO_UNI(cp) && \
c4c8e615
KW
152( ( 0x2000 <= NATIVE_TO_UNI(cp) && NATIVE_TO_UNI(cp) <= 0x200A ) || ( 0x200A < NATIVE_TO_UNI(cp) &&\
153( 0x2028 == NATIVE_TO_UNI(cp) || ( 0x2028 < NATIVE_TO_UNI(cp) && \
154( 0x2029 == NATIVE_TO_UNI(cp) || ( 0x2029 < NATIVE_TO_UNI(cp) && \
155( 0x202F == NATIVE_TO_UNI(cp) || ( 0x202F < NATIVE_TO_UNI(cp) && \
a9c9e371 156( 0x205F == NATIVE_TO_UNI(cp) || 0x3000 == NATIVE_TO_UNI(cp) ) ) ) ) ) ) ) ) ) ) )
bedac28b
KW
157
158/*
b96a92fb
KW
159 REPLACEMENT: Unicode REPLACEMENT CHARACTER
160
161 0xFFFD
162*/
163/*** GENERATED CODE ***/
164#define is_REPLACEMENT_utf8_safe(s,e) \
5ab0c3af 165( ( ( ( ( ((e) - (s)) >= 3 ) && ( 0xEF == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ) && ( 0xBF == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ) && ( 0xBD == NATIVE_TO_LATIN1(((U8*)s)[2]) ) ) ? 3 : 0 )
b96a92fb
KW
166
167/*
168 NONCHAR: Non character code points
169
170 \p{Nchar}
171*/
172/*** GENERATED CODE ***/
173#define is_NONCHAR_utf8(s) \
c4c8e615
KW
174( ( 0xEF == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
175 ( ( 0xB7 == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ? \
176 ( ( 0x90 <= NATIVE_TO_LATIN1(((U8*)s)[2]) && NATIVE_TO_LATIN1(((U8*)s)[2]) <= 0xAF ) ? 3 : 0 )\
177 : ( ( 0xBF == NATIVE_TO_LATIN1(((U8*)s)[1]) ) && ( NATIVE_TO_LATIN1(((U8*)s)[2]) >= 0xBE ) ) ? 3 : 0 )\
178: ( 0xF0 == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
179 ( ( ( ( NATIVE_TO_LATIN1(((U8*)s)[1]) == 0x9F || ( ( NATIVE_TO_LATIN1(((U8*)s)[1]) & 0xEF ) == 0xAF ) ) && ( 0xBF == NATIVE_TO_LATIN1(((U8*)s)[2]) ) ) && ( NATIVE_TO_LATIN1(((U8*)s)[3]) >= 0xBE ) ) ? 4 : 0 )\
180: ( 0xF1 <= NATIVE_TO_LATIN1(((U8*)s)[0]) && NATIVE_TO_LATIN1(((U8*)s)[0]) <= 0xF3 ) ?\
181 ( ( ( ( ( NATIVE_TO_LATIN1(((U8*)s)[1]) & 0xCF ) == 0x8F ) && ( 0xBF == NATIVE_TO_LATIN1(((U8*)s)[2]) ) ) && ( NATIVE_TO_LATIN1(((U8*)s)[3]) >= 0xBE ) ) ? 4 : 0 )\
182: ( ( ( ( 0xF4 == NATIVE_TO_LATIN1(((U8*)s)[0]) ) && ( 0x8F == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ) && ( 0xBF == NATIVE_TO_LATIN1(((U8*)s)[2]) ) ) && ( NATIVE_TO_LATIN1(((U8*)s)[3]) >= 0xBE ) ) ? 4 : 0 )
b96a92fb
KW
183
184/*
185 SURROGATE: Surrogate characters
186
187 \p{Gc=Cs}
188*/
189/*** GENERATED CODE ***/
190#define is_SURROGATE_utf8(s) \
c4c8e615 191( ( ( 0xED == NATIVE_TO_LATIN1(((U8*)s)[0]) ) && ( NATIVE_TO_LATIN1(((U8*)s)[1]) >= 0xA0 ) ) ? 3 : 0 )
b96a92fb
KW
192
193/*
612ead59
KW
194 GCB_L: Grapheme_Cluster_Break=L
195
196 \p{_X_GCB_L}
197*/
198/*** GENERATED CODE ***/
199#define is_GCB_L_utf8(s) \
c4c8e615
KW
200( ( 0xE1 == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
201 ( ( 0x84 == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ? \
6e130234 202 3 \
c4c8e615
KW
203 : ( ( 0x85 == NATIVE_TO_LATIN1(((U8*)s)[1]) ) && ( NATIVE_TO_LATIN1(((U8*)s)[2]) <= 0x9F ) ) ? 3 : 0 )\
204: ( ( ( 0xEA == NATIVE_TO_LATIN1(((U8*)s)[0]) ) && ( 0xA5 == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ) && ( 0xA0 <= NATIVE_TO_LATIN1(((U8*)s)[2]) && NATIVE_TO_LATIN1(((U8*)s)[2]) <= 0xBC ) ) ? 3 : 0 )
612ead59
KW
205
206/*
207 GCB_LV_LVT_V: Grapheme_Cluster_Break=(LV or LVT or V)
208
209 \p{_X_LV_LVT_V}
210*/
211/*** GENERATED CODE ***/
212#define is_GCB_LV_LVT_V_utf8(s) \
c4c8e615
KW
213( ( 0xE1 == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
214 ( ( 0x85 == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ? \
215 ( ( NATIVE_TO_LATIN1(((U8*)s)[2]) >= 0xA0 ) ? 3 : 0 ) \
216 : ( ( 0x86 == NATIVE_TO_LATIN1(((U8*)s)[1]) ) && ( NATIVE_TO_LATIN1(((U8*)s)[2]) <= 0xA7 ) ) ? 3 : 0 )\
217: ( 0xEA == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
218 ( ( NATIVE_TO_LATIN1(((U8*)s)[1]) >= 0xB0 ) ? \
6e130234
KW
219 3 \
220 : 0 ) \
c4c8e615 221: ( 0xEB == NATIVE_TO_LATIN1(((U8*)s)[0]) || 0xEC == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ?\
6e130234 222 3 \
c4c8e615
KW
223: ( 0xED == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
224 ( ( NATIVE_TO_LATIN1(((U8*)s)[1]) <= 0x9D ) ? \
6e130234 225 3 \
c4c8e615
KW
226 : ( 0x9E == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ? \
227 ( ( ( NATIVE_TO_LATIN1(((U8*)s)[2]) <= 0xA3 ) || ( NATIVE_TO_LATIN1(((U8*)s)[2]) >= 0xB0 ) ) ? 3 : 0 )\
228 : ( ( 0x9F == NATIVE_TO_LATIN1(((U8*)s)[1]) ) && ( NATIVE_TO_LATIN1(((U8*)s)[2]) <= 0x86 ) ) ? 3 : 0 )\
612ead59
KW
229: 0 )
230
231/*
232 GCB_Prepend: Grapheme_Cluster_Break=Prepend
233
234 \p{_X_GCB_Prepend}
235*/
236/*** GENERATED CODE ***/
237#define is_GCB_Prepend_utf8(s) \
238( 0 )
239
240/*
241 GCB_RI: Grapheme_Cluster_Break=RI
242
243 \p{_X_RI}
244*/
245/*** GENERATED CODE ***/
246#define is_GCB_RI_utf8(s) \
c4c8e615 247( ( ( ( ( 0xF0 == NATIVE_TO_LATIN1(((U8*)s)[0]) ) && ( 0x9F == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ) && ( 0x87 == NATIVE_TO_LATIN1(((U8*)s)[2]) ) ) && ( NATIVE_TO_LATIN1(((U8*)s)[3]) >= 0xA6 ) ) ? 4 : 0 )
612ead59
KW
248
249/*
bff53399 250 GCB_SPECIAL_BEGIN_START: Grapheme_Cluster_Break=special_begin_starts
612ead59 251
bff53399 252 \p{_X_Special_Begin_Start}
612ead59
KW
253*/
254/*** GENERATED CODE ***/
bff53399 255#define is_GCB_SPECIAL_BEGIN_START_utf8(s) \
c4c8e615
KW
256( ( 0xE1 == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
257 ( ( ( NATIVE_TO_LATIN1(((U8*)s)[1]) & 0xFC ) == 0x84 ) ? \
6e130234
KW
258 3 \
259 : 0 ) \
c4c8e615
KW
260: ( 0xEA == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
261 ( ( 0xA5 == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ? \
262 ( ( 0xA0 <= NATIVE_TO_LATIN1(((U8*)s)[2]) && NATIVE_TO_LATIN1(((U8*)s)[2]) <= 0xBC ) ? 3 : 0 )\
263 : ( NATIVE_TO_LATIN1(((U8*)s)[1]) >= 0xB0 ) ? \
6e130234 264 3 \
612ead59 265 : 0 ) \
c4c8e615 266: ( 0xEB == NATIVE_TO_LATIN1(((U8*)s)[0]) || 0xEC == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ?\
6e130234 267 3 \
c4c8e615
KW
268: ( 0xED == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
269 ( ( NATIVE_TO_LATIN1(((U8*)s)[1]) <= 0x9D ) ? \
6e130234 270 3 \
c4c8e615
KW
271 : ( 0x9E == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ? \
272 ( ( ( NATIVE_TO_LATIN1(((U8*)s)[2]) <= 0xA3 ) || ( NATIVE_TO_LATIN1(((U8*)s)[2]) >= 0xB0 ) ) ? 3 : 0 )\
273 : ( ( 0x9F == NATIVE_TO_LATIN1(((U8*)s)[1]) ) && ( ( NATIVE_TO_LATIN1(((U8*)s)[2]) <= 0x86 ) || ( 0x8B <= NATIVE_TO_LATIN1(((U8*)s)[2]) && NATIVE_TO_LATIN1(((U8*)s)[2]) <= 0xBB ) ) ) ? 3 : 0 )\
274: ( ( ( ( 0xF0 == NATIVE_TO_LATIN1(((U8*)s)[0]) ) && ( 0x9F == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ) && ( 0x87 == NATIVE_TO_LATIN1(((U8*)s)[2]) ) ) && ( NATIVE_TO_LATIN1(((U8*)s)[3]) >= 0xA6 ) ) ? 4 : 0 )
612ead59
KW
275
276/*
277 GCB_T: Grapheme_Cluster_Break=T
278
279 \p{_X_GCB_T}
280*/
281/*** GENERATED CODE ***/
282#define is_GCB_T_utf8(s) \
c4c8e615
KW
283( ( 0xE1 == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
284 ( ( 0x86 == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ? \
285 ( ( NATIVE_TO_LATIN1(((U8*)s)[2]) >= 0xA8 ) ? 3 : 0 ) \
286 : ( 0x87 == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ? \
6e130234 287 3 \
612ead59 288 : 0 ) \
c4c8e615 289: ( ( ( 0xED == NATIVE_TO_LATIN1(((U8*)s)[0]) ) && ( 0x9F == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ) && ( 0x8B <= NATIVE_TO_LATIN1(((U8*)s)[2]) && NATIVE_TO_LATIN1(((U8*)s)[2]) <= 0xBB ) ) ? 3 : 0 )
612ead59
KW
290
291/*
292 GCB_V: Grapheme_Cluster_Break=V
293
294 \p{_X_GCB_V}
295*/
296/*** GENERATED CODE ***/
297#define is_GCB_V_utf8(s) \
c4c8e615
KW
298( ( 0xE1 == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
299 ( ( 0x85 == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ? \
300 ( ( NATIVE_TO_LATIN1(((U8*)s)[2]) >= 0xA0 ) ? 3 : 0 ) \
301 : ( ( 0x86 == NATIVE_TO_LATIN1(((U8*)s)[1]) ) && ( NATIVE_TO_LATIN1(((U8*)s)[2]) <= 0xA7 ) ) ? 3 : 0 )\
302: ( 0xED == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
303 ( ( 0x9E == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ? \
304 ( ( NATIVE_TO_LATIN1(((U8*)s)[2]) >= 0xB0 ) ? 3 : 0 ) \
305 : ( ( 0x9F == NATIVE_TO_LATIN1(((U8*)s)[1]) ) && ( NATIVE_TO_LATIN1(((U8*)s)[2]) <= 0x86 ) ) ? 3 : 0 )\
612ead59
KW
306: 0 )
307
685289b5
KW
308/*
309 QUOTEMETA: Meta-characters that \Q should quote
310
311 \p{_Perl_Quotemeta}
312*/
313/*** GENERATED CODE ***/
314#define is_QUOTEMETA_high(s) \
c4c8e615
KW
315( ( 0xCD == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
316 ( ( 0x8F == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ? 2 : 0 ) \
a9c9e371
KW
317: ( 0xD8 == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
318 ( ( 0x9C == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ? 2 : 0 ) \
c4c8e615
KW
319: ( 0xE1 == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
320 ( ( 0x85 == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ? \
321 ( ( 0x9F == NATIVE_TO_LATIN1(((U8*)s)[2]) || 0xA0 == NATIVE_TO_LATIN1(((U8*)s)[2]) ) ? 3 : 0 )\
322 : ( 0x9A == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ? \
323 ( ( 0x80 == NATIVE_TO_LATIN1(((U8*)s)[2]) ) ? 3 : 0 ) \
324 : ( 0x9E == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ? \
325 ( ( ( NATIVE_TO_LATIN1(((U8*)s)[2]) & 0xFE ) == 0xB4 ) ? 3 : 0 ) \
326 : ( ( 0xA0 == NATIVE_TO_LATIN1(((U8*)s)[1]) ) && ( 0x8B <= NATIVE_TO_LATIN1(((U8*)s)[2]) && NATIVE_TO_LATIN1(((U8*)s)[2]) <= 0x8E ) ) ? 3 : 0 )\
327: ( 0xE2 == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
328 ( ( 0x80 == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ? \
329 ( ( NATIVE_TO_LATIN1(((U8*)s)[2]) <= 0xBE ) ? 3 : 0 ) \
330 : ( 0x81 == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ? \
331 ( ( ( 0x81 <= NATIVE_TO_LATIN1(((U8*)s)[2]) && NATIVE_TO_LATIN1(((U8*)s)[2]) <= 0x93 ) || ( 0x95 <= NATIVE_TO_LATIN1(((U8*)s)[2]) && NATIVE_TO_LATIN1(((U8*)s)[2]) <= 0xAF ) ) ? 3 : 0 )\
332 : ( 0x86 == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ? \
333 ( ( NATIVE_TO_LATIN1(((U8*)s)[2]) >= 0x90 ) ? 3 : 0 ) \
334 : ( ( 0x87 <= NATIVE_TO_LATIN1(((U8*)s)[1]) && NATIVE_TO_LATIN1(((U8*)s)[1]) <= 0x90 ) || ( 0x94 <= NATIVE_TO_LATIN1(((U8*)s)[1]) && NATIVE_TO_LATIN1(((U8*)s)[1]) <= 0x9C ) || ( 0x9F <= NATIVE_TO_LATIN1(((U8*)s)[1]) && NATIVE_TO_LATIN1(((U8*)s)[1]) <= 0xAF ) || ( NATIVE_TO_LATIN1(((U8*)s)[1]) & 0xFE ) == 0xB8 ) ?\
6e130234 335 3 \
c4c8e615
KW
336 : ( 0x91 == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ? \
337 ( ( NATIVE_TO_LATIN1(((U8*)s)[2]) <= 0x9F ) ? 3 : 0 ) \
338 : ( 0x9D == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ? \
339 ( ( NATIVE_TO_LATIN1(((U8*)s)[2]) <= 0xB5 ) ? 3 : 0 ) \
340 : ( ( 0x9E == NATIVE_TO_LATIN1(((U8*)s)[1]) ) && ( NATIVE_TO_LATIN1(((U8*)s)[2]) >= 0x94 ) ) ? 3 : 0 )\
341: ( 0xE3 == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
342 ( ( 0x80 == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ? \
343 ( ( ( NATIVE_TO_LATIN1(((U8*)s)[2]) <= 0x83 ) || ( 0x88 <= NATIVE_TO_LATIN1(((U8*)s)[2]) && NATIVE_TO_LATIN1(((U8*)s)[2]) <= 0xA0 ) || 0xB0 == NATIVE_TO_LATIN1(((U8*)s)[2]) ) ? 3 : 0 )\
344 : ( ( 0x85 == NATIVE_TO_LATIN1(((U8*)s)[1]) ) && ( 0xA4 == NATIVE_TO_LATIN1(((U8*)s)[2]) ) ) ? 3 : 0 )\
345: ( 0xEF == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
346 ( ( 0xB4 == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ? \
347 ( ( NATIVE_TO_LATIN1(((U8*)s)[2]) >= 0xBE ) ? 3 : 0 ) \
348 : ( 0xB8 == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ? \
349 ( ( NATIVE_TO_LATIN1(((U8*)s)[2]) <= 0x8F ) ? 3 : 0 ) \
350 : ( 0xB9 == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ? \
351 ( ( 0x85 == NATIVE_TO_LATIN1(((U8*)s)[2]) || 0x86 == NATIVE_TO_LATIN1(((U8*)s)[2]) ) ? 3 : 0 )\
352 : ( 0xBB == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ? \
353 ( ( 0xBF == NATIVE_TO_LATIN1(((U8*)s)[2]) ) ? 3 : 0 ) \
354 : ( 0xBE == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ? \
355 ( ( 0xA0 == NATIVE_TO_LATIN1(((U8*)s)[2]) ) ? 3 : 0 ) \
356 : ( ( 0xBF == NATIVE_TO_LATIN1(((U8*)s)[1]) ) && ( 0xB0 <= NATIVE_TO_LATIN1(((U8*)s)[2]) && NATIVE_TO_LATIN1(((U8*)s)[2]) <= 0xB8 ) ) ? 3 : 0 )\
357: ( 0xF0 == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
358 ( ( ( ( 0x9D == NATIVE_TO_LATIN1(((U8*)s)[1]) ) && ( 0x85 == NATIVE_TO_LATIN1(((U8*)s)[2]) ) ) && ( 0xB3 <= NATIVE_TO_LATIN1(((U8*)s)[3]) && NATIVE_TO_LATIN1(((U8*)s)[3]) <= 0xBA ) ) ? 4 : 0 )\
359: ( ( 0xF3 == NATIVE_TO_LATIN1(((U8*)s)[0]) ) && ( 0xA0 == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ) ? 4 : 0 )
685289b5 360
8769f413
KW
361/*
362 MULTI_CHAR_FOLD: multi-char strings that are folded to by a single character
363
364 do regen/regcharclass_multi_char_folds.pl
365 &regcharclass_multi_char_folds::multi_char_folds(1)
366*/
367/*** GENERATED CODE ***/
251b239f
KW
368#define is_MULTI_CHAR_FOLD_utf8_safe_part0(s,e) \
369( ( 0x73 == NATIVE_TO_LATIN1(((U8*)s)[1]) || 0x74 == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ? 2 : 0 )
370
371
372/*** GENERATED CODE ***/
373#define is_MULTI_CHAR_FOLD_utf8_safe_part1(s,e) \
374( ( 0x74 == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
375 ( ( ( 0xCC == NATIVE_TO_LATIN1(((U8*)s)[1]) ) && ( 0x88 == NATIVE_TO_LATIN1(((U8*)s)[2]) ) ) ? 3 : 0 )\
376 : ( 0x77 == NATIVE_TO_LATIN1(((U8*)s)[0]) || 0x79 == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ?\
377 ( ( ( 0xCC == NATIVE_TO_LATIN1(((U8*)s)[1]) ) && ( 0x8A == NATIVE_TO_LATIN1(((U8*)s)[2]) ) ) ? 3 : 0 )\
378 : ( 0xC5 == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
379 ( ( ( ( 0xBF == NATIVE_TO_LATIN1(((U8*)s)[1]) ) && ( 0xC5 == NATIVE_TO_LATIN1(((U8*)s)[2]) ) ) && ( 0xBF == NATIVE_TO_LATIN1(((U8*)s)[3]) ) ) ? 4 : 0 )\
380 : ( 0xCA == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
381 ( ( ( 0xBC == NATIVE_TO_LATIN1(((U8*)s)[1]) ) && ( 0x6E == NATIVE_TO_LATIN1(((U8*)s)[2]) ) ) ? 3 : 0 )\
382 : ( 0xCE == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
383 ( ( ( NATIVE_TO_LATIN1(((U8*)s)[1]) & 0xFD ) == 0xAC ) ? \
384 ( ( ( 0xCE == NATIVE_TO_LATIN1(((U8*)s)[2]) ) && ( 0xB9 == NATIVE_TO_LATIN1(((U8*)s)[3]) ) ) ? 4 : 0 )\
385 : ( 0xB1 == NATIVE_TO_LATIN1(((U8*)s)[1]) || 0xB7 == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ?\
386 ( ( 0xCD == NATIVE_TO_LATIN1(((U8*)s)[2]) ) ? \
387 ( ( 0x82 == NATIVE_TO_LATIN1(((U8*)s)[3]) ) ? \
388 ( ( ( 0xCE == NATIVE_TO_LATIN1(((U8*)s)[4]) ) && ( 0xB9 == NATIVE_TO_LATIN1(((U8*)s)[5]) ) ) ? 6 : 4 )\
389 : 0 ) \
390 : ( ( 0xCE == NATIVE_TO_LATIN1(((U8*)s)[2]) ) && ( 0xB9 == NATIVE_TO_LATIN1(((U8*)s)[3]) ) ) ? 4 : 0 )\
391 : ( 0xB9 == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ? \
392 ( ( 0xCC == NATIVE_TO_LATIN1(((U8*)s)[2]) ) ? \
393 ( ( 0x88 == NATIVE_TO_LATIN1(((U8*)s)[3]) ) ? \
394 ( ( 0xCC == NATIVE_TO_LATIN1(((U8*)s)[4]) ) ? \
395 ( ( ( NATIVE_TO_LATIN1(((U8*)s)[5]) & 0xFE ) == 0x80 ) ? 6 : 0 )\
396 : ( ( 0xCD == NATIVE_TO_LATIN1(((U8*)s)[4]) ) && ( 0x82 == NATIVE_TO_LATIN1(((U8*)s)[5]) ) ) ? 6 : 0 )\
397 : 0 ) \
398 : ( ( 0xCD == NATIVE_TO_LATIN1(((U8*)s)[2]) ) && ( 0x82 == NATIVE_TO_LATIN1(((U8*)s)[3]) ) ) ? 4 : 0 )\
399 : 0 ) \
400 : ( 0xCF == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
401 ( ( 0x81 == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ? \
402 ( ( ( 0xCC == NATIVE_TO_LATIN1(((U8*)s)[2]) ) && ( 0x93 == NATIVE_TO_LATIN1(((U8*)s)[3]) ) ) ? 4 : 0 )\
403 : ( 0x85 == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ? \
404 ( ( 0xCC == NATIVE_TO_LATIN1(((U8*)s)[2]) ) ? \
405 ( ( 0x88 == NATIVE_TO_LATIN1(((U8*)s)[3]) ) ? \
406 ( ( 0xCC == NATIVE_TO_LATIN1(((U8*)s)[4]) ) ? \
407 ( ( ( NATIVE_TO_LATIN1(((U8*)s)[5]) & 0xFE ) == 0x80 ) ? 6 : 0 )\
408 : ( ( 0xCD == NATIVE_TO_LATIN1(((U8*)s)[4]) ) && ( 0x82 == NATIVE_TO_LATIN1(((U8*)s)[5]) ) ) ? 6 : 0 )\
409 : ( 0x93 == NATIVE_TO_LATIN1(((U8*)s)[3]) ) ? \
410 ( ( 0xCC == NATIVE_TO_LATIN1(((U8*)s)[4]) ) ? \
411 ( ( ( NATIVE_TO_LATIN1(((U8*)s)[5]) & 0xFE ) == 0x80 ) ? 6 : 4 )\
412 : ( ( 0xCD == NATIVE_TO_LATIN1(((U8*)s)[4]) ) && ( 0x82 == NATIVE_TO_LATIN1(((U8*)s)[5]) ) ) ? 6 : 4 )\
413 : 0 ) \
414 : ( ( 0xCD == NATIVE_TO_LATIN1(((U8*)s)[2]) ) && ( 0x82 == NATIVE_TO_LATIN1(((U8*)s)[3]) ) ) ? 4 : 0 )\
415 : ( 0x89 == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ? \
416 ( ( 0xCD == NATIVE_TO_LATIN1(((U8*)s)[2]) ) ? \
417 ( ( 0x82 == NATIVE_TO_LATIN1(((U8*)s)[3]) ) ? \
418 ( ( ( 0xCE == NATIVE_TO_LATIN1(((U8*)s)[4]) ) && ( 0xB9 == NATIVE_TO_LATIN1(((U8*)s)[5]) ) ) ? 6 : 4 )\
419 : 0 ) \
420 : ( ( 0xCE == NATIVE_TO_LATIN1(((U8*)s)[2]) ) && ( 0xB9 == NATIVE_TO_LATIN1(((U8*)s)[3]) ) ) ? 4 : 0 )\
421 : ( ( ( 0x8E == NATIVE_TO_LATIN1(((U8*)s)[1]) ) && ( 0xCE == NATIVE_TO_LATIN1(((U8*)s)[2]) ) ) && ( 0xB9 == NATIVE_TO_LATIN1(((U8*)s)[3]) ) ) ? 4 : 0 )\
422 : ( 0xD5 == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
423 ( ( 0xA5 == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ? \
424 ( ( ( 0xD6 == NATIVE_TO_LATIN1(((U8*)s)[2]) ) && ( 0x82 == NATIVE_TO_LATIN1(((U8*)s)[3]) ) ) ? 4 : 0 )\
425 : ( 0xB4 == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ? \
426 ( ( ( 0xD5 == NATIVE_TO_LATIN1(((U8*)s)[2]) ) && ( ( ( NATIVE_TO_LATIN1(((U8*)s)[3]) & 0xF7 ) == 0xA5 ) || NATIVE_TO_LATIN1(((U8*)s)[3]) == 0xAB || NATIVE_TO_LATIN1(((U8*)s)[3]) == 0xB6 ) ) ? 4 : 0 )\
427 : ( ( ( 0xBE == NATIVE_TO_LATIN1(((U8*)s)[1]) ) && ( 0xD5 == NATIVE_TO_LATIN1(((U8*)s)[2]) ) ) && ( 0xB6 == NATIVE_TO_LATIN1(((U8*)s)[3]) ) ) ? 4 : 0 )\
428 : ( 0xE1 == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
429 ( ( 0xBC == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ? \
430 ( ( ( ( ( NATIVE_TO_LATIN1(((U8*)s)[2]) & 0xD8 ) == 0x80 ) && ( 0xCE == NATIVE_TO_LATIN1(((U8*)s)[3]) ) ) && ( 0xB9 == NATIVE_TO_LATIN1(((U8*)s)[4]) ) ) ? 5 : 0 )\
431 : ( ( ( ( 0xBD == NATIVE_TO_LATIN1(((U8*)s)[1]) ) && ( ( ( NATIVE_TO_LATIN1(((U8*)s)[2]) & 0xF8 ) == 0xA0 ) || ( ( NATIVE_TO_LATIN1(((U8*)s)[2]) & 0xFB ) == 0xB0 ) || NATIVE_TO_LATIN1(((U8*)s)[2]) == 0xBC ) ) && ( 0xCE == NATIVE_TO_LATIN1(((U8*)s)[3]) ) ) && ( 0xB9 == NATIVE_TO_LATIN1(((U8*)s)[4]) ) ) ? 5 : 0 )\
432 : 0 )
433
434
435/*** GENERATED CODE ***/
436#define is_MULTI_CHAR_FOLD_utf8_safe_part2(s,e) \
437( ( 0x61 == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
438 ( ( ( 0xCA == NATIVE_TO_LATIN1(((U8*)s)[1]) ) && ( 0xBE == NATIVE_TO_LATIN1(((U8*)s)[2]) ) ) ? 3 : 0 )\
439 : ( 0x66 == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
440 ( ( 0x66 == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ? \
441 ( ( 0x69 == NATIVE_TO_LATIN1(((U8*)s)[2]) || 0x6C == NATIVE_TO_LATIN1(((U8*)s)[2]) ) ? 3 : 2 )\
442 : ( 0x69 == NATIVE_TO_LATIN1(((U8*)s)[1]) || 0x6C == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ? 2 : 0 )\
443 : ( 0x68 == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
444 ( ( ( 0xCC == NATIVE_TO_LATIN1(((U8*)s)[1]) ) && ( 0xB1 == NATIVE_TO_LATIN1(((U8*)s)[2]) ) ) ? 3 : 0 )\
445 : ( 0x69 == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
446 ( ( ( 0xCC == NATIVE_TO_LATIN1(((U8*)s)[1]) ) && ( 0x87 == NATIVE_TO_LATIN1(((U8*)s)[2]) ) ) ? 3 : 0 )\
447 : ( 0x6A == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
448 ( ( ( 0xCC == NATIVE_TO_LATIN1(((U8*)s)[1]) ) && ( 0x8C == NATIVE_TO_LATIN1(((U8*)s)[2]) ) ) ? 3 : 0 )\
449 : ( 0x73 == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
450 ( ( 0x73 == NATIVE_TO_LATIN1(((U8*)s)[1]) || 0x74 == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ? 2 : 0 )\
451 : ( 0x74 == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
452 ( ( ( 0xCC == NATIVE_TO_LATIN1(((U8*)s)[1]) ) && ( 0x88 == NATIVE_TO_LATIN1(((U8*)s)[2]) ) ) ? 3 : 0 )\
453 : ( 0x77 == NATIVE_TO_LATIN1(((U8*)s)[0]) || 0x79 == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ?\
454 ( ( ( 0xCC == NATIVE_TO_LATIN1(((U8*)s)[1]) ) && ( 0x8A == NATIVE_TO_LATIN1(((U8*)s)[2]) ) ) ? 3 : 0 )\
455 : ( 0xC5 == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
456 ( ( ( ( 0xBF == NATIVE_TO_LATIN1(((U8*)s)[1]) ) && ( 0xC5 == NATIVE_TO_LATIN1(((U8*)s)[2]) ) ) && ( 0xBF == NATIVE_TO_LATIN1(((U8*)s)[3]) ) ) ? 4 : 0 )\
457 : ( 0xCA == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
458 ( ( ( 0xBC == NATIVE_TO_LATIN1(((U8*)s)[1]) ) && ( 0x6E == NATIVE_TO_LATIN1(((U8*)s)[2]) ) ) ? 3 : 0 )\
459 : ( 0xCE == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
460 ( ( ( NATIVE_TO_LATIN1(((U8*)s)[1]) & 0xFD ) == 0xAC ) ? \
461 ( ( ( 0xCE == NATIVE_TO_LATIN1(((U8*)s)[2]) ) && ( 0xB9 == NATIVE_TO_LATIN1(((U8*)s)[3]) ) ) ? 4 : 0 )\
462 : ( 0xB1 == NATIVE_TO_LATIN1(((U8*)s)[1]) || 0xB7 == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ?\
463 ( ( 0xCD == NATIVE_TO_LATIN1(((U8*)s)[2]) ) ? \
464 ( ( 0x82 == NATIVE_TO_LATIN1(((U8*)s)[3]) ) ? 4 : 0 ) \
465 : ( ( 0xCE == NATIVE_TO_LATIN1(((U8*)s)[2]) ) && ( 0xB9 == NATIVE_TO_LATIN1(((U8*)s)[3]) ) ) ? 4 : 0 )\
466 : ( ( ( 0xB9 == NATIVE_TO_LATIN1(((U8*)s)[1]) ) && ( 0xCD == NATIVE_TO_LATIN1(((U8*)s)[2]) ) ) && ( 0x82 == NATIVE_TO_LATIN1(((U8*)s)[3]) ) ) ? 4 : 0 )\
467 : ( 0xCF == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
468 ( ( 0x81 == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ? \
469 ( ( ( 0xCC == NATIVE_TO_LATIN1(((U8*)s)[2]) ) && ( 0x93 == NATIVE_TO_LATIN1(((U8*)s)[3]) ) ) ? 4 : 0 )\
470 : ( 0x85 == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ? \
471 ( ( 0xCC == NATIVE_TO_LATIN1(((U8*)s)[2]) ) ? \
472 ( ( 0x93 == NATIVE_TO_LATIN1(((U8*)s)[3]) ) ? 4 : 0 ) \
473 : ( ( 0xCD == NATIVE_TO_LATIN1(((U8*)s)[2]) ) && ( 0x82 == NATIVE_TO_LATIN1(((U8*)s)[3]) ) ) ? 4 : 0 )\
474 : ( 0x89 == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ? \
475 ( ( 0xCD == NATIVE_TO_LATIN1(((U8*)s)[2]) ) ? \
476 ( ( 0x82 == NATIVE_TO_LATIN1(((U8*)s)[3]) ) ? 4 : 0 ) \
477 : ( ( 0xCE == NATIVE_TO_LATIN1(((U8*)s)[2]) ) && ( 0xB9 == NATIVE_TO_LATIN1(((U8*)s)[3]) ) ) ? 4 : 0 )\
478 : ( ( ( 0x8E == NATIVE_TO_LATIN1(((U8*)s)[1]) ) && ( 0xCE == NATIVE_TO_LATIN1(((U8*)s)[2]) ) ) && ( 0xB9 == NATIVE_TO_LATIN1(((U8*)s)[3]) ) ) ? 4 : 0 )\
479 : ( 0xD5 == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
480 ( ( 0xA5 == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ? \
481 ( ( ( 0xD6 == NATIVE_TO_LATIN1(((U8*)s)[2]) ) && ( 0x82 == NATIVE_TO_LATIN1(((U8*)s)[3]) ) ) ? 4 : 0 )\
482 : ( 0xB4 == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ? \
483 ( ( ( 0xD5 == NATIVE_TO_LATIN1(((U8*)s)[2]) ) && ( ( ( NATIVE_TO_LATIN1(((U8*)s)[3]) & 0xF7 ) == 0xA5 ) || NATIVE_TO_LATIN1(((U8*)s)[3]) == 0xAB || NATIVE_TO_LATIN1(((U8*)s)[3]) == 0xB6 ) ) ? 4 : 0 )\
484 : ( ( ( 0xBE == NATIVE_TO_LATIN1(((U8*)s)[1]) ) && ( 0xD5 == NATIVE_TO_LATIN1(((U8*)s)[2]) ) ) && ( 0xB6 == NATIVE_TO_LATIN1(((U8*)s)[3]) ) ) ? 4 : 0 )\
485 : 0 )
486
487
488/*** GENERATED CODE ***/
489#define is_MULTI_CHAR_FOLD_utf8_safe_part3(s,e) \
490( ((e)-(s) > 2) ? \
491 ( ( 0x61 == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
492 ( ( ( 0xCA == NATIVE_TO_LATIN1(((U8*)s)[1]) ) && ( 0xBE == NATIVE_TO_LATIN1(((U8*)s)[2]) ) ) ? 3 : 0 )\
493 : ( 0x66 == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
494 ( ( 0x66 == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ? \
495 ( ( 0x69 == NATIVE_TO_LATIN1(((U8*)s)[2]) || 0x6C == NATIVE_TO_LATIN1(((U8*)s)[2]) ) ? 3 : 2 )\
496 : ( 0x69 == NATIVE_TO_LATIN1(((U8*)s)[1]) || 0x6C == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ? 2 : 0 )\
497 : ( 0x68 == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
498 ( ( ( 0xCC == NATIVE_TO_LATIN1(((U8*)s)[1]) ) && ( 0xB1 == NATIVE_TO_LATIN1(((U8*)s)[2]) ) ) ? 3 : 0 )\
499 : ( 0x69 == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
500 ( ( ( 0xCC == NATIVE_TO_LATIN1(((U8*)s)[1]) ) && ( 0x87 == NATIVE_TO_LATIN1(((U8*)s)[2]) ) ) ? 3 : 0 )\
501 : ( 0x6A == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
502 ( ( ( 0xCC == NATIVE_TO_LATIN1(((U8*)s)[1]) ) && ( 0x8C == NATIVE_TO_LATIN1(((U8*)s)[2]) ) ) ? 3 : 0 )\
503 : ( 0x73 == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
504 ( ( 0x73 == NATIVE_TO_LATIN1(((U8*)s)[1]) || 0x74 == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ? 2 : 0 )\
505 : ( 0x74 == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
506 ( ( ( 0xCC == NATIVE_TO_LATIN1(((U8*)s)[1]) ) && ( 0x88 == NATIVE_TO_LATIN1(((U8*)s)[2]) ) ) ? 3 : 0 )\
507 : ( 0x77 == NATIVE_TO_LATIN1(((U8*)s)[0]) || 0x79 == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ?\
508 ( ( ( 0xCC == NATIVE_TO_LATIN1(((U8*)s)[1]) ) && ( 0x8A == NATIVE_TO_LATIN1(((U8*)s)[2]) ) ) ? 3 : 0 )\
509 : ( ( ( 0xCA == NATIVE_TO_LATIN1(((U8*)s)[0]) ) && ( 0xBC == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ) && ( 0x6E == NATIVE_TO_LATIN1(((U8*)s)[2]) ) ) ? 3 : 0 )\
510: ((e)-(s) > 1) ? \
511 ( ( 0x66 == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
512 ( ( 0x66 == NATIVE_TO_LATIN1(((U8*)s)[1]) || 0x69 == NATIVE_TO_LATIN1(((U8*)s)[1]) || 0x6C == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ? 2 : 0 )\
513 : ( ( 0x73 == NATIVE_TO_LATIN1(((U8*)s)[0]) ) && ( 0x73 == NATIVE_TO_LATIN1(((U8*)s)[1]) || 0x74 == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ) ? 2 : 0 )\
c4c8e615
KW
514: 0 )
515
516
517/*** GENERATED CODE ***/
251b239f 518#define is_MULTI_CHAR_FOLD_utf8_safe_part4(s,e) \
c4c8e615 519( ( 0x61 == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
251b239f
KW
520 ( ( ( 0xCA == NATIVE_TO_LATIN1(((U8*)s)[1]) ) && ( 0xBE == NATIVE_TO_LATIN1(((U8*)s)[2]) ) ) ? 3 : 0 )\
521 : ( 0x66 == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
522 ( ( 0x66 == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ? \
523 ( ( 0x69 == NATIVE_TO_LATIN1(((U8*)s)[2]) || 0x6C == NATIVE_TO_LATIN1(((U8*)s)[2]) ) ? 3 : 2 )\
524 : ( 0x69 == NATIVE_TO_LATIN1(((U8*)s)[1]) || 0x6C == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ? 2 : 0 )\
525 : ( 0x68 == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
526 ( ( ( 0xCC == NATIVE_TO_LATIN1(((U8*)s)[1]) ) && ( 0xB1 == NATIVE_TO_LATIN1(((U8*)s)[2]) ) ) ? 3 : 0 )\
527 : ( 0x69 == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
528 ( ( ( 0xCC == NATIVE_TO_LATIN1(((U8*)s)[1]) ) && ( 0x87 == NATIVE_TO_LATIN1(((U8*)s)[2]) ) ) ? 3 : 0 )\
529 : ( 0x6A == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
530 ( ( ( 0xCC == NATIVE_TO_LATIN1(((U8*)s)[1]) ) && ( 0x8C == NATIVE_TO_LATIN1(((U8*)s)[2]) ) ) ? 3 : 0 )\
531 : ( 0x73 == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? is_MULTI_CHAR_FOLD_utf8_safe_part0(s,e) : is_MULTI_CHAR_FOLD_utf8_safe_part1(s,e) )
532
533
534/*** GENERATED CODE ***/
535#define is_MULTI_CHAR_FOLD_utf8_safe_part5(s,e) \
536( ((e)-(s) > 4) ? \
537 ( ( 0x61 == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
538 ( ( ( 0xCA == NATIVE_TO_LATIN1(((U8*)s)[1]) ) && ( 0xBE == NATIVE_TO_LATIN1(((U8*)s)[2]) ) ) ? 3 : 0 )\
539 : ( 0x66 == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
540 ( ( 0x66 == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ? \
541 ( ( 0x69 == NATIVE_TO_LATIN1(((U8*)s)[2]) || 0x6C == NATIVE_TO_LATIN1(((U8*)s)[2]) ) ? 3 : 2 )\
542 : ( 0x69 == NATIVE_TO_LATIN1(((U8*)s)[1]) || 0x6C == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ? 2 : 0 )\
543 : ( 0x68 == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
544 ( ( ( 0xCC == NATIVE_TO_LATIN1(((U8*)s)[1]) ) && ( 0xB1 == NATIVE_TO_LATIN1(((U8*)s)[2]) ) ) ? 3 : 0 )\
545 : ( 0x69 == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
546 ( ( ( 0xCC == NATIVE_TO_LATIN1(((U8*)s)[1]) ) && ( 0x87 == NATIVE_TO_LATIN1(((U8*)s)[2]) ) ) ? 3 : 0 )\
547 : ( 0x6A == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
548 ( ( ( 0xCC == NATIVE_TO_LATIN1(((U8*)s)[1]) ) && ( 0x8C == NATIVE_TO_LATIN1(((U8*)s)[2]) ) ) ? 3 : 0 )\
549 : ( 0x73 == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
550 ( ( 0x73 == NATIVE_TO_LATIN1(((U8*)s)[1]) || 0x74 == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ? 2 : 0 )\
551 : ( 0x74 == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
552 ( ( ( 0xCC == NATIVE_TO_LATIN1(((U8*)s)[1]) ) && ( 0x88 == NATIVE_TO_LATIN1(((U8*)s)[2]) ) ) ? 3 : 0 )\
553 : ( 0x77 == NATIVE_TO_LATIN1(((U8*)s)[0]) || 0x79 == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ?\
554 ( ( ( 0xCC == NATIVE_TO_LATIN1(((U8*)s)[1]) ) && ( 0x8A == NATIVE_TO_LATIN1(((U8*)s)[2]) ) ) ? 3 : 0 )\
555 : ( 0xC5 == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
556 ( ( ( ( 0xBF == NATIVE_TO_LATIN1(((U8*)s)[1]) ) && ( 0xC5 == NATIVE_TO_LATIN1(((U8*)s)[2]) ) ) && ( 0xBF == NATIVE_TO_LATIN1(((U8*)s)[3]) ) ) ? 4 : 0 )\
557 : ( 0xCA == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
558 ( ( ( 0xBC == NATIVE_TO_LATIN1(((U8*)s)[1]) ) && ( 0x6E == NATIVE_TO_LATIN1(((U8*)s)[2]) ) ) ? 3 : 0 )\
559 : ( 0xCE == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
560 ( ( ( NATIVE_TO_LATIN1(((U8*)s)[1]) & 0xFD ) == 0xAC ) ? \
561 ( ( ( 0xCE == NATIVE_TO_LATIN1(((U8*)s)[2]) ) && ( 0xB9 == NATIVE_TO_LATIN1(((U8*)s)[3]) ) ) ? 4 : 0 )\
562 : ( 0xB1 == NATIVE_TO_LATIN1(((U8*)s)[1]) || 0xB7 == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ?\
563 ( ( 0xCD == NATIVE_TO_LATIN1(((U8*)s)[2]) ) ? \
564 ( ( 0x82 == NATIVE_TO_LATIN1(((U8*)s)[3]) ) ? 4 : 0 ) \
565 : ( ( 0xCE == NATIVE_TO_LATIN1(((U8*)s)[2]) ) && ( 0xB9 == NATIVE_TO_LATIN1(((U8*)s)[3]) ) ) ? 4 : 0 )\
566 : ( ( ( 0xB9 == NATIVE_TO_LATIN1(((U8*)s)[1]) ) && ( 0xCD == NATIVE_TO_LATIN1(((U8*)s)[2]) ) ) && ( 0x82 == NATIVE_TO_LATIN1(((U8*)s)[3]) ) ) ? 4 : 0 )\
567 : ( 0xCF == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
568 ( ( 0x81 == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ? \
569 ( ( ( 0xCC == NATIVE_TO_LATIN1(((U8*)s)[2]) ) && ( 0x93 == NATIVE_TO_LATIN1(((U8*)s)[3]) ) ) ? 4 : 0 )\
570 : ( 0x85 == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ? \
571 ( ( 0xCC == NATIVE_TO_LATIN1(((U8*)s)[2]) ) ? \
572 ( ( 0x93 == NATIVE_TO_LATIN1(((U8*)s)[3]) ) ? 4 : 0 ) \
573 : ( ( 0xCD == NATIVE_TO_LATIN1(((U8*)s)[2]) ) && ( 0x82 == NATIVE_TO_LATIN1(((U8*)s)[3]) ) ) ? 4 : 0 )\
574 : ( 0x89 == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ? \
575 ( ( 0xCD == NATIVE_TO_LATIN1(((U8*)s)[2]) ) ? \
576 ( ( 0x82 == NATIVE_TO_LATIN1(((U8*)s)[3]) ) ? 4 : 0 ) \
577 : ( ( 0xCE == NATIVE_TO_LATIN1(((U8*)s)[2]) ) && ( 0xB9 == NATIVE_TO_LATIN1(((U8*)s)[3]) ) ) ? 4 : 0 )\
578 : ( ( ( 0x8E == NATIVE_TO_LATIN1(((U8*)s)[1]) ) && ( 0xCE == NATIVE_TO_LATIN1(((U8*)s)[2]) ) ) && ( 0xB9 == NATIVE_TO_LATIN1(((U8*)s)[3]) ) ) ? 4 : 0 )\
579 : ( 0xD5 == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
580 ( ( 0xA5 == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ? \
581 ( ( ( 0xD6 == NATIVE_TO_LATIN1(((U8*)s)[2]) ) && ( 0x82 == NATIVE_TO_LATIN1(((U8*)s)[3]) ) ) ? 4 : 0 )\
582 : ( 0xB4 == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ? \
583 ( ( ( 0xD5 == NATIVE_TO_LATIN1(((U8*)s)[2]) ) && ( ( ( NATIVE_TO_LATIN1(((U8*)s)[3]) & 0xF7 ) == 0xA5 ) || NATIVE_TO_LATIN1(((U8*)s)[3]) == 0xAB || NATIVE_TO_LATIN1(((U8*)s)[3]) == 0xB6 ) ) ? 4 : 0 )\
584 : ( ( ( 0xBE == NATIVE_TO_LATIN1(((U8*)s)[1]) ) && ( 0xD5 == NATIVE_TO_LATIN1(((U8*)s)[2]) ) ) && ( 0xB6 == NATIVE_TO_LATIN1(((U8*)s)[3]) ) ) ? 4 : 0 )\
585 : ( 0xE1 == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
586 ( ( 0xBC == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ? \
587 ( ( ( ( ( NATIVE_TO_LATIN1(((U8*)s)[2]) & 0xD8 ) == 0x80 ) && ( 0xCE == NATIVE_TO_LATIN1(((U8*)s)[3]) ) ) && ( 0xB9 == NATIVE_TO_LATIN1(((U8*)s)[4]) ) ) ? 5 : 0 )\
588 : ( ( ( ( 0xBD == NATIVE_TO_LATIN1(((U8*)s)[1]) ) && ( ( ( NATIVE_TO_LATIN1(((U8*)s)[2]) & 0xF8 ) == 0xA0 ) || ( ( NATIVE_TO_LATIN1(((U8*)s)[2]) & 0xFB ) == 0xB0 ) || NATIVE_TO_LATIN1(((U8*)s)[2]) == 0xBC ) ) && ( 0xCE == NATIVE_TO_LATIN1(((U8*)s)[3]) ) ) && ( 0xB9 == NATIVE_TO_LATIN1(((U8*)s)[4]) ) ) ? 5 : 0 )\
589 : 0 ) \
590: ((e)-(s) > 3) ? is_MULTI_CHAR_FOLD_utf8_safe_part2(s,e) : is_MULTI_CHAR_FOLD_utf8_safe_part3(s,e) )
591
592
593/*** GENERATED CODE ***/
594#define is_MULTI_CHAR_FOLD_utf8_safe(s,e) \
595( ((e)-(s) > 5) ? is_MULTI_CHAR_FOLD_utf8_safe_part4(s,e) : is_MULTI_CHAR_FOLD_utf8_safe_part5(s,e) )
8769f413
KW
596
597/*
40b1ba4f 598 MULTI_CHAR_FOLD: multi-char strings that are folded to by a single character
8769f413
KW
599
600 &regcharclass_multi_char_folds::multi_char_folds(0)
601*/
602/*** GENERATED CODE ***/
251b239f
KW
603#define is_MULTI_CHAR_FOLD_latin1_safe(s,e) \
604( ((e)-(s) > 2) ? \
605 ( ( ( NATIVE_TO_LATIN1(((U8*)s)[0]) & 0xDF ) == 0x46 ) ? \
606 ( ( ( NATIVE_TO_LATIN1(((U8*)s)[1]) & 0xDF ) == 0x46 ) ? \
607 ( ( ( ( NATIVE_TO_LATIN1(((U8*)s)[2]) & 0xDF ) == 0x49 ) || ( ( NATIVE_TO_LATIN1(((U8*)s)[2]) & 0xDF ) == 0x4C ) ) ? 3 : 2 )\
608 : ( ( ( NATIVE_TO_LATIN1(((U8*)s)[1]) & 0xDF ) == 0x49 ) || ( ( NATIVE_TO_LATIN1(((U8*)s)[1]) & 0xDF ) == 0x4C ) ) ? 2 : 0 )\
609 : ( ( ( NATIVE_TO_LATIN1(((U8*)s)[0]) & 0xDF ) == 0x53 ) && ( ( ( NATIVE_TO_LATIN1(((U8*)s)[1]) & 0xDF ) == 0x53 ) || ( ( NATIVE_TO_LATIN1(((U8*)s)[1]) & 0xDF ) == 0x54 ) ) ) ? 2 : 0 )\
610: ((e)-(s) > 1) ? \
611 ( ( ( NATIVE_TO_LATIN1(((U8*)s)[0]) & 0xDF ) == 0x46 ) ? \
612 ( ( ( ( NATIVE_TO_LATIN1(((U8*)s)[1]) & 0xDF ) == 0x46 ) || ( ( NATIVE_TO_LATIN1(((U8*)s)[1]) & 0xDF ) == 0x49 ) || ( ( NATIVE_TO_LATIN1(((U8*)s)[1]) & 0xDF ) == 0x4C ) ) ? 2 : 0 )\
613 : ( ( ( NATIVE_TO_LATIN1(((U8*)s)[0]) & 0xDF ) == 0x53 ) && ( ( ( NATIVE_TO_LATIN1(((U8*)s)[1]) & 0xDF ) == 0x53 ) || ( ( NATIVE_TO_LATIN1(((U8*)s)[1]) & 0xDF ) == 0x54 ) ) ) ? 2 : 0 )\
614: 0 )
8769f413 615
0b50d62a 616/*
1a27eb96
KW
617 FOLDS_TO_MULTI: characters that fold to multi-char strings
618
619 \p{_Perl_Folds_To_Multi_Char}
620*/
621/*** GENERATED CODE ***/
622#define is_FOLDS_TO_MULTI_utf8(s) \
623( ( 0xC3 == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
624 ( ( 0x9F == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ? 2 : 0 ) \
625: ( 0xC4 == NATIVE_TO_LATIN1(((U8*)s)[0]) || 0xC7 == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ?\
626 ( ( 0xB0 == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ? 2 : 0 ) \
627: ( 0xC5 == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
628 ( ( 0x89 == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ? 2 : 0 ) \
629: ( 0xCE == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
630 ( ( ( NATIVE_TO_LATIN1(((U8*)s)[1]) & 0xDF ) == 0x90 ) ? 2 : 0 ) \
631: ( 0xD6 == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
632 ( ( 0x87 == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ? 2 : 0 ) \
633: ( 0xE1 == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
634 ( ( 0xBA == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ? \
635 ( ( ( 0x96 <= NATIVE_TO_LATIN1(((U8*)s)[2]) && NATIVE_TO_LATIN1(((U8*)s)[2]) <= 0x9A ) || 0x9E == NATIVE_TO_LATIN1(((U8*)s)[2]) ) ? 3 : 0 )\
636 : ( 0xBD == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ? \
637 ( ( ( NATIVE_TO_LATIN1(((U8*)s)[2]) & 0xF9 ) == 0x90 ) ? 3 : 0 ) \
638 : ( 0xBE == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ? \
639 ( ( ( ( NATIVE_TO_LATIN1(((U8*)s)[2]) & 0xE0 ) == 0x80 ) || ( ( NATIVE_TO_LATIN1(((U8*)s)[2]) & 0xF0 ) == 0xA0 ) || ( ( NATIVE_TO_LATIN1(((U8*)s)[2]) & 0xFA ) == 0xB2 ) || ( ( NATIVE_TO_LATIN1(((U8*)s)[2]) & 0xF7 ) == 0xB4 ) ) ? 3 : 0 )\
640 : ( ( 0xBF == NATIVE_TO_LATIN1(((U8*)s)[1]) ) && ( ( ( NATIVE_TO_LATIN1(((U8*)s)[2]) & 0xCA ) == 0x82 ) || ( ( NATIVE_TO_LATIN1(((U8*)s)[2]) & 0xF7 ) == 0x84 ) || NATIVE_TO_LATIN1(((U8*)s)[2]) == 0xA4 || ( ( NATIVE_TO_LATIN1(((U8*)s)[2]) & 0xF7 ) == 0xB4 ) ) ) ? 3 : 0 )\
641: ( ( ( 0xEF == NATIVE_TO_LATIN1(((U8*)s)[0]) ) && ( 0xAC == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ) && ( ( NATIVE_TO_LATIN1(((U8*)s)[2]) <= 0x86 ) || ( 0x93 <= NATIVE_TO_LATIN1(((U8*)s)[2]) && NATIVE_TO_LATIN1(((U8*)s)[2]) <= 0x97 ) ) ) ? 3 : 0 )
642
643/*
31f05a37
KW
644 PROBLEMATIC_LOCALE_FOLD: characters whose fold is problematic under locale
645
646 \p{_Perl_Problematic_Locale_Folds}
647*/
648/*** GENERATED CODE ***/
649#define is_PROBLEMATIC_LOCALE_FOLD_utf8(s) \
726137b5 650( ( NATIVE_TO_LATIN1(((U8*)s)[0]) <= 0x7F ) ? 1 \
31f05a37
KW
651: ( ( NATIVE_TO_LATIN1(((U8*)s)[0]) & 0xFE ) == 0xC2 ) ? \
652 2 \
653: ( 0xC4 == NATIVE_TO_LATIN1(((U8*)s)[0]) || 0xC7 == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ?\
654 ( ( 0xB0 == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ? 2 : 0 ) \
655: ( 0xC5 == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
656 ( ( 0x89 == NATIVE_TO_LATIN1(((U8*)s)[1]) || 0xB8 == NATIVE_TO_LATIN1(((U8*)s)[1]) || 0xBF == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ? 2 : 0 )\
657: ( 0xCE == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
658 ( ( ( NATIVE_TO_LATIN1(((U8*)s)[1]) & 0xDF ) == 0x9C ) ? 2 : 0 ) \
659: ( 0xE1 == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
660 ( ( ( 0xBA == NATIVE_TO_LATIN1(((U8*)s)[1]) ) && ( ( 0x96 <= NATIVE_TO_LATIN1(((U8*)s)[2]) && NATIVE_TO_LATIN1(((U8*)s)[2]) <= 0x9A ) || 0x9E == NATIVE_TO_LATIN1(((U8*)s)[2]) ) ) ? 3 : 0 )\
661: ( 0xE2 == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
662 ( ( ( 0x84 == NATIVE_TO_LATIN1(((U8*)s)[1]) ) && ( ( NATIVE_TO_LATIN1(((U8*)s)[2]) & 0xFE ) == 0xAA ) ) ? 3 : 0 )\
663: ( ( ( 0xEF == NATIVE_TO_LATIN1(((U8*)s)[0]) ) && ( 0xAC == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ) && ( NATIVE_TO_LATIN1(((U8*)s)[2]) <= 0x86 ) ) ? 3 : 0 )
664
665/*** GENERATED CODE ***/
666#define is_PROBLEMATIC_LOCALE_FOLD_cp(cp) \
667( NATIVE_TO_UNI(cp) <= 0xFF || ( 0xFF < NATIVE_TO_UNI(cp) && \
668( 0x130 == NATIVE_TO_UNI(cp) || ( 0x130 < NATIVE_TO_UNI(cp) && \
669( 0x149 == NATIVE_TO_UNI(cp) || ( 0x149 < NATIVE_TO_UNI(cp) && \
670( 0x178 == NATIVE_TO_UNI(cp) || ( 0x178 < NATIVE_TO_UNI(cp) && \
671( 0x17F == NATIVE_TO_UNI(cp) || ( 0x17F < NATIVE_TO_UNI(cp) && \
672( 0x1F0 == NATIVE_TO_UNI(cp) || ( 0x1F0 < NATIVE_TO_UNI(cp) && \
673( 0x39C == NATIVE_TO_UNI(cp) || ( 0x39C < NATIVE_TO_UNI(cp) && \
674( 0x3BC == NATIVE_TO_UNI(cp) || ( 0x3BC < NATIVE_TO_UNI(cp) && \
675( ( 0x1E96 <= NATIVE_TO_UNI(cp) && NATIVE_TO_UNI(cp) <= 0x1E9A ) || ( 0x1E9A < NATIVE_TO_UNI(cp) &&\
676( 0x1E9E == NATIVE_TO_UNI(cp) || ( 0x1E9E < NATIVE_TO_UNI(cp) && \
677( 0x212A == NATIVE_TO_UNI(cp) || ( 0x212A < NATIVE_TO_UNI(cp) && \
678( 0x212B == NATIVE_TO_UNI(cp) || ( 0xFB00 <= NATIVE_TO_UNI(cp) && NATIVE_TO_UNI(cp) <= 0xFB06 ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) )
679
680/*
681 PROBLEMATIC_LOCALE_FOLDEDS_START: The first folded character of folds which are problematic under locale
682
683 \p{_Perl_Problematic_Locale_Foldeds_Start}
684*/
685/*** GENERATED CODE ***/
686#define is_PROBLEMATIC_LOCALE_FOLDEDS_START_utf8(s) \
726137b5 687( ( NATIVE_TO_LATIN1(((U8*)s)[0]) <= 0x7F ) ? 1 \
31f05a37
KW
688: ( ( NATIVE_TO_LATIN1(((U8*)s)[0]) & 0xFE ) == 0xC2 ) ? \
689 2 \
690: ( 0xC4 == NATIVE_TO_LATIN1(((U8*)s)[0]) || 0xC7 == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ?\
691 ( ( 0xB0 == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ? 2 : 0 ) \
692: ( 0xC5 == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
693 ( ( 0x89 == NATIVE_TO_LATIN1(((U8*)s)[1]) || 0xB8 == NATIVE_TO_LATIN1(((U8*)s)[1]) || 0xBF == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ? 2 : 0 )\
694: ( 0xCA == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
695 ( ( 0xBC == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ? 2 : 0 ) \
696: ( 0xCE == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
697 ( ( ( NATIVE_TO_LATIN1(((U8*)s)[1]) & 0xDF ) == 0x9C ) ? 2 : 0 ) \
698: ( 0xE1 == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
699 ( ( ( 0xBA == NATIVE_TO_LATIN1(((U8*)s)[1]) ) && ( ( 0x96 <= NATIVE_TO_LATIN1(((U8*)s)[2]) && NATIVE_TO_LATIN1(((U8*)s)[2]) <= 0x9A ) || 0x9E == NATIVE_TO_LATIN1(((U8*)s)[2]) ) ) ? 3 : 0 )\
700: ( 0xE2 == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
701 ( ( ( 0x84 == NATIVE_TO_LATIN1(((U8*)s)[1]) ) && ( ( NATIVE_TO_LATIN1(((U8*)s)[2]) & 0xFE ) == 0xAA ) ) ? 3 : 0 )\
702: ( ( ( 0xEF == NATIVE_TO_LATIN1(((U8*)s)[0]) ) && ( 0xAC == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ) && ( NATIVE_TO_LATIN1(((U8*)s)[2]) <= 0x86 ) ) ? 3 : 0 )
703
704/*** GENERATED CODE ***/
705#define is_PROBLEMATIC_LOCALE_FOLDEDS_START_cp(cp) \
706( NATIVE_TO_UNI(cp) <= 0xFF || ( 0xFF < NATIVE_TO_UNI(cp) && \
707( 0x130 == NATIVE_TO_UNI(cp) || ( 0x130 < NATIVE_TO_UNI(cp) && \
708( 0x149 == NATIVE_TO_UNI(cp) || ( 0x149 < NATIVE_TO_UNI(cp) && \
709( 0x178 == NATIVE_TO_UNI(cp) || ( 0x178 < NATIVE_TO_UNI(cp) && \
710( 0x17F == NATIVE_TO_UNI(cp) || ( 0x17F < NATIVE_TO_UNI(cp) && \
711( 0x1F0 == NATIVE_TO_UNI(cp) || ( 0x1F0 < NATIVE_TO_UNI(cp) && \
712( 0x2BC == NATIVE_TO_UNI(cp) || ( 0x2BC < NATIVE_TO_UNI(cp) && \
713( 0x39C == NATIVE_TO_UNI(cp) || ( 0x39C < NATIVE_TO_UNI(cp) && \
714( 0x3BC == NATIVE_TO_UNI(cp) || ( 0x3BC < NATIVE_TO_UNI(cp) && \
715( ( 0x1E96 <= NATIVE_TO_UNI(cp) && NATIVE_TO_UNI(cp) <= 0x1E9A ) || ( 0x1E9A < NATIVE_TO_UNI(cp) &&\
716( 0x1E9E == NATIVE_TO_UNI(cp) || ( 0x1E9E < NATIVE_TO_UNI(cp) && \
717( 0x212A == NATIVE_TO_UNI(cp) || ( 0x212A < NATIVE_TO_UNI(cp) && \
718( 0x212B == NATIVE_TO_UNI(cp) || ( 0xFB00 <= NATIVE_TO_UNI(cp) && NATIVE_TO_UNI(cp) <= 0xFB06 ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) )
719
720/*
0b50d62a
KW
721 PATWS: pattern white space
722
723 \p{PatWS}
724*/
725/*** GENERATED CODE ***/
0b50d62a 726#define is_PATWS_safe(s,e,is_utf8) \
5ab0c3af 727( ((e) > (s)) ? \
c4c8e615 728 ( ( ( 0x09 <= NATIVE_TO_LATIN1(((U8*)s)[0]) && NATIVE_TO_LATIN1(((U8*)s)[0]) <= 0x0D ) || 0x20 == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? 1\
5ab0c3af
KW
729 : (! is_utf8 ) ? \
730 ( 0x85 == NATIVE_TO_LATIN1(((U8*)s)[0]) ) \
731 : (((e) - (s)) >= UTF8SKIP(s)) ? \
732 ( ( 0xC2 == NATIVE_TO_LATIN1(((U8*)s)[0]) ) ? \
733 ( ( 0x85 == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ? 2 : 0 ) \
734 : ( ( ( 0xE2 == NATIVE_TO_LATIN1(((U8*)s)[0]) ) && ( 0x80 == NATIVE_TO_LATIN1(((U8*)s)[1]) ) ) && ( ( NATIVE_TO_LATIN1(((U8*)s)[2]) & 0xFE ) == 0x8E || ( NATIVE_TO_LATIN1(((U8*)s)[2]) & 0xFE ) == 0xA8 ) ) ? 3 : 0 )\
735 : 0 ) \
0b50d62a
KW
736: 0 )
737
738/*** GENERATED CODE ***/
739#define is_PATWS_cp(cp) \
c4c8e615
KW
740( ( 0x09 <= NATIVE_TO_UNI(cp) && NATIVE_TO_UNI(cp) <= 0x0D ) || ( 0x0D < NATIVE_TO_UNI(cp) &&\
741( 0x20 == NATIVE_TO_UNI(cp) || ( 0x20 < NATIVE_TO_UNI(cp) && \
742( 0x85 == NATIVE_TO_UNI(cp) || ( 0x85 < NATIVE_TO_UNI(cp) && \
743( 0x200E == NATIVE_TO_UNI(cp) || ( 0x200E < NATIVE_TO_UNI(cp) && \
744( 0x200F == NATIVE_TO_UNI(cp) || ( 0x200F < NATIVE_TO_UNI(cp) && \
745( 0x2028 == NATIVE_TO_UNI(cp) || 0x2029 == NATIVE_TO_UNI(cp) ) ) ) ) ) ) ) ) ) ) )
0b50d62a 746
8770da0e 747
d10c72f2
KW
748#endif /* H_REGCHARCLASS */
749
58fbde93 750/* ex: set ro: */