Fix mnemonics.
[kopensolaris-gnu/glibc.git] / posix / PTESTS
1 # 2.8.2  Regular Expression General Requirement
2 2¦4¦bb*¦abbbc¦
3 2¦2¦bb*¦ababbbc¦
4 7¦9¦A#*::¦A:A#:qA::qA#::qA##::q¦
5 1¦5¦A#*::¦A##::A#::qA::qA#:q¦
6 # 2.8.3.1.2  BRE Special Characters
7 # GA108
8 2¦2¦\.¦a.c¦
9 2¦2¦\[¦a[c¦
10 2¦2¦\\¦a\c¦
11 2¦2¦\*¦a*c¦
12 2¦2¦\^¦a^c¦
13 2¦2¦\$¦a$c¦
14 7¦11¦X\*Y\*8¦Y*8X*8X*Y*8¦
15 # GA109
16 2¦2¦[.]¦a.c¦
17 2¦2¦[[]¦a[c¦
18 -1¦-1¦[[]¦ac¦
19 2¦2¦[\]¦a\c¦
20 1¦1¦[\a]¦abc¦
21 2¦2¦[\.]¦a\.c¦
22 2¦2¦[\.]¦a.\c¦
23 2¦2¦[*]¦a*c¦
24 2¦2¦[$]¦a$c¦
25 2¦2¦[X*Y8]¦7*8YX¦
26 # GA110
27 2¦2¦*¦a*c¦
28 3¦4¦*a¦*b*a*c¦
29 1¦5¦**9=¦***9=9¦
30 # GA111
31 1¦1¦^*¦*bc¦
32 -1¦-1¦^*¦a*c¦
33 -1¦-1¦^*¦^*ab¦
34 1¦5¦^**9=¦***9=¦
35 -1¦-1¦^*5<*9¦5<9*5<*9¦
36 # GA112
37 2¦3¦\(*b\)¦a*b¦
38 -1¦-1¦\(*b\)¦ac¦
39 1¦6¦A\(**9\)=¦A***9=79¦
40 # GA113(1)
41 1¦3¦\(^*ab\)¦*ab¦
42 -1¦-1¦\(^*ab\)¦^*ab¦
43 -1¦-1¦\(^*b\)¦a*b¦
44 -1¦-1¦\(^*b\)¦^*b¦
45 ### GA113(2)                    GNU regex implements GA113(1)
46 ##-1¦-1¦\(^*ab\)¦*ab¦
47 ##-1¦-1¦\(^*ab\)¦^*ab¦
48 ##1¦1¦\(^*b\)¦b¦
49 ##1¦3¦\(^*b\)¦^^b¦
50 # GA114
51 1¦3¦a^b¦a^b¦
52 1¦3¦a\^b¦a^b¦
53 1¦1¦^^¦^bc¦
54 2¦2¦\^¦a^c¦
55 1¦1¦[c^b]¦^abc¦
56 1¦1¦[\^ab]¦^ab¦
57 2¦2¦[\^ab]¦c\d¦
58 -1¦-1¦[^^]¦^¦
59 1¦3¦\(a^b\)¦a^b¦
60 1¦3¦\(a\^b\)¦a^b¦
61 2¦2¦\(\^\)¦a^b¦
62 # GA115
63 3¦3¦$$¦ab$¦
64 -1¦-1¦$$¦$ab¦
65 2¦3¦$c¦a$c¦
66 2¦2¦[$]¦a$c¦
67 1¦2¦\$a¦$a¦
68 3¦3¦\$$¦ab$¦
69 2¦6¦A\([34]$[34]\)B¦XA4$3BY¦
70 # 2.8.3.1.3  Periods in BREs
71 # GA116
72 1¦1¦.¦abc¦
73 -1¦-1¦.ab¦abc¦
74 1¦3¦ab.¦abc¦
75 1¦3¦a.b¦a,b¦
76 -1¦-1¦.......¦PqRs6¦
77 1¦7¦.......¦PqRs6T8¦
78 # 2.8.3.2  RE Bracket Expression
79 # GA118
80 2¦2¦[abc]¦xbyz¦
81 -1¦-1¦[abc]¦xyz¦
82 2¦2¦[abc]¦xbay¦
83 # GA119
84 2¦2¦[^a]¦abc¦
85 4¦4¦[^]cd]¦cd]ef¦
86 2¦2¦[^abc]¦axyz¦
87 -1¦-1¦[^abc]¦abc¦
88 3¦3¦[^[.a.]b]¦abc¦
89 3¦3¦[^[=a=]b]¦abc¦
90 2¦2¦[^-ac]¦abcde-¦
91 2¦2¦[^ac-]¦abcde-¦
92 3¦3¦[^a-b]¦abcde¦
93 3¦3¦[^a-bd-e]¦dec¦
94 2¦2¦[^---]¦-ab¦
95 16¦16¦[^a-zA-Z0-9]¦pqrstVWXYZ23579#¦
96 # GA120(1)
97 3¦3¦[]a]¦cd]ef¦
98 1¦1¦[]-a]¦a_b¦
99 3¦3¦[][.-.]-0]¦ab0-]¦
100 1¦1¦[]^a-z]¦string¦
101 # GA120(2)
102 4¦4¦[^]cd]¦cd]ef¦
103 0¦0¦[^]]*¦]]]]]]]]X¦
104 0¦0¦[^]]*¦]]]]]]]]¦
105 9¦9¦[^]]\{1,\}¦]]]]]]]]X¦
106 -1¦-1¦[^]]\{1,\}¦]]]]]]]]¦
107 # GA120(3)
108 3¦3¦[c[.].]d]¦ab]cd¦
109 2¦8¦[a-z]*[[.].]][A-Z]*¦Abcd]DEFg¦
110 # GA121
111 2¦2¦[[.a.]b]¦Abc¦
112 1¦1¦[[.a.]b]¦aBc¦
113 -1¦-1¦[[.a.]b]¦ABc¦
114 3¦3¦[^[.a.]b]¦abc¦
115 3¦3¦[][.-.]-0]¦ab0-]¦
116 3¦3¦[A-[.].]c]¦ab]!¦
117 # GA122
118 -2¦-2¦[[.ch]]¦abc¦
119 -2¦-2¦[[.ab.][.CD.][.EF.]]¦yZabCDEFQ9¦
120 # GA125
121 2¦2¦[[=a=]b]¦Abc¦
122 1¦1¦[[=a=]b]¦aBc¦
123 -1¦-1¦[[=a=]b]¦ABc¦
124 3¦3¦[^[=a=]b]¦abc¦
125 # GA126
126 2¦7¦[[:alnum:]]*¦ aB28gH¦
127 2¦5¦[^[:alnum:]]*¦2     ,\7f
128 2¦5¦[[:alpha:]]*¦ aBgH2¦
129 1¦6¦[^[:alpha:]]*¦2     8,\7f
130 1¦2¦[[:blank:]]*¦       \r\7f¦
131 1¦8¦[^[:blank:]]*¦aB28gH,\7f ¦
132 1¦2¦[[:cntrl:]]*¦       \7f ¦
133 1¦8¦[^[:cntrl:]]*¦aB2 8gh,¦
134 2¦3¦[[:digit:]]*¦a28¦
135 1¦8¦[^[:digit:]]*¦aB    gH,\7f¦
136 1¦7¦[[:graph:]]*¦aB28gH, ¦
137 1¦3¦[^[:graph:]]*¦      \7f
138 1¦2¦[[:lower:]]*¦agB¦
139 1¦8¦[^[:lower:]]*¦B2    8H,\7f
140 1¦8¦[[:print:]]*¦aB2 8gH,       ¦
141 1¦2¦[^[:print:]]*¦      \7f ¦
142 2¦2¦[[:punct:]]*¦a,2¦
143 1¦9¦[^[:punct:]]*¦aB2   8gH\7f¦
144 1¦3¦[[:space:]]*¦       \r\7f¦
145 2¦9¦[^[:space:]]*¦ aB28gH,\7f     ¦
146 2¦3¦[[:upper:]]*¦aBH2¦
147 1¦8¦[^[:upper:]]*¦a2    8g,\7f
148 2¦5¦[[:xdigit:]]*¦gaB28h¦
149 2¦7¦[^[:xdigit:]]*¦a    gH,\7f
150 # GA127
151 -2¦-2¦[b-a]¦abc¦
152 1¦1¦[a-c]¦bbccde¦
153 2¦2¦[a-b]¦-bc¦
154 3¦3¦[a-z0-9]¦AB0¦
155 3¦3¦[^a-b]¦abcde¦
156 3¦3¦[^a-bd-e]¦dec¦
157 1¦1¦[]-a]¦a_b¦
158 2¦2¦[+--]¦a,b¦
159 2¦2¦[--/]¦a.b¦
160 2¦2¦[^---]¦-ab¦
161 3¦3¦[][.-.]-0]¦ab0-]¦
162 3¦3¦[A-[.].]c]¦ab]!¦
163 2¦6¦bc[d-w]xy¦abchxyz¦
164 # GA129
165 1¦1¦[a-cd-f]¦dbccde¦
166 -1¦-1¦[a-ce-f¦dBCCdE¦
167 2¦4¦b[n-zA-M]Y¦absY9Z¦
168 2¦4¦b[n-zA-M]Y¦abGY9Z¦
169 # GA130
170 3¦3¦[-xy]¦ac-¦
171 2¦4¦[c[-xy]D¦ac-D+¦
172 2¦2¦[--/]¦a.b¦
173 2¦4¦c[--/]D¦ac.D+b¦
174 2¦2¦[^-ac]¦abcde-¦
175 1¦3¦a[^-ac]c¦abcde-¦
176 3¦3¦[xy-]¦zc-¦
177 2¦4¦c[xy-]7¦zc-786¦
178 2¦2¦[^ac-]¦abcde-¦
179 2¦4¦a[^ac-]c¦5abcde-¦
180 2¦2¦[+--]¦a,b¦
181 2¦4¦a[+--]B¦Xa,By¦
182 2¦2¦[^---]¦-ab¦
183 4¦6¦X[^---]Y¦X-YXaYXbY¦
184 # 2.8.3.3  BREs Matching Multiple Characters
185 # GA131
186 3¦4¦cd¦abcdeabcde¦
187 1¦2¦ag*b¦abcde¦
188 -1¦-1¦[a-c][e-f]¦abcdef¦
189 3¦4¦[a-c][e-f]¦acbedf¦
190 4¦8¦abc*XYZ¦890abXYZ#*¦
191 4¦9¦abc*XYZ¦890abcXYZ#*¦
192 4¦15¦abc*XYZ¦890abccccccccXYZ#*¦
193 -1¦-1¦abc*XYZ¦890abc*XYZ#*¦
194 # GA132
195 2¦4¦\(*bc\)¦a*bc¦
196 1¦2¦\(ab\)¦abcde¦
197 1¦10¦\(a\(b\(c\(d\(e\(f\(g\)h\(i\(j\)\)\)\)\)\)\)\)¦abcdefghijk¦
198 3¦8¦43\(2\(6\)*0\)AB¦654320ABCD¦
199 3¦9¦43\(2\(7\)*0\)AB¦6543270ABCD¦
200 3¦12¦43\(2\(7\)*0\)AB¦6543277770ABCD¦
201 # GA133
202 1¦10¦\(a\(b\(c\(d\(e\(f\(g\)h\(i\(j\)\)\)\)\)\)\)\)¦abcdefghijk¦
203 -1¦-1¦\(a\(b\(c\(d\(e\(f\(g\)h\(i\(k\)\)\)\)\)\)\)\)¦abcdefghijk¦
204 # GA134
205 2¦4¦\(bb*\)¦abbbc¦
206 2¦2¦\(bb*\)¦ababbbc¦
207 1¦6¦a\(.*b\)¦ababbbc¦
208 1¦2¦a\(b*\)¦ababbbc¦
209 1¦20¦a\(.*b\)c¦axcaxbbbcsxbbbbbbbbc¦
210 # GA135
211 1¦7¦\(a\(b\(c\(d\(e\)\)\)\)\)\4¦abcdededede¦
212 1¦2¦a\(b\)*c\1¦acb¦
213 1¦11¦\(a\(b\(c\(d\(e\(f\(g\)h\(i\(j\)\)\)\)\)\)\)\)\9¦abcdefghijjk¦
214 # GA136
215 1¦2¦a\(b\)*c\1¦acb¦
216 4¦7¦a\(b\(c\(d\(f\)*\)\)\)\4¦xYzabcdePQRST¦
217 # GA137
218 -2¦-2¦\(a\(b\)\)\3¦foo¦
219 -2¦-2¦\(a\(b\)\)\(a\(b\)\)\5¦foo¦
220 # GA138
221 1¦2¦ag*b¦abcde¦
222 1¦10¦a.*b¦abababvbabc¦
223 2¦5¦b*c¦abbbcdeabbbbbbcde¦
224 2¦5¦bbb*c¦abbbcdeabbbbbbcde¦
225 1¦5¦a\(b\)*c\1¦abbcbbb¦
226 -1¦-1¦a\(b\)*c\1¦abbdbd¦
227 0¦0¦\([a-c]*\)\1¦abcacdef¦
228 1¦6¦\([a-c]*\)\1¦abcabcabcd¦
229 1¦2¦a^*b¦ab¦
230 1¦5¦a^*b¦a^^^b¦
231 # GA139
232 1¦2¦a\{2\}¦aaaa¦
233 1¦7¦\([a-c]*\)\{0,\}¦aabcaab¦
234 1¦2¦\(a\)\1\{1,2\}¦aabc¦
235 1¦3¦\(a\)010\{1,2\}¦aaaabc¦
236 1¦4¦\(\(a\)\1\)\{1,2\}¦aaaabc¦
237 # GA140
238 1¦2¦a\{2\}¦aaaa¦
239 -1¦-1¦a\{2\}¦abcd¦
240 0¦0¦a\{0\}¦aaaa¦
241 1¦64¦a\{64\}¦aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa¦
242 # GA141
243 1¦7¦\([a-c]*\)\{0,\}¦aabcaab¦
244 -1¦-1¦\([a-c]*\)\{2,\}¦abcdefg¦
245 1¦3¦\([a-c]*\)\{1,\}¦abcdefg¦
246 -1¦-1¦a\{64,\}¦aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa¦
247 # GA142
248 1¦3¦a\{2,3\}¦aaaa¦
249 -1¦-1¦a\{2,3\}¦abcd¦
250 0¦0¦\([a-c]*\)\{0,0\}¦foo¦
251 1¦63¦a\{1,63\}¦aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa¦
252 # 2.8.3.4  BRE Precedence
253 # GA143
254 2¦20¦\^\[[[.].]]\\(\\1\\)\\*\\{1,2\\}\$¦a^[]\(1\)\*\{1,2\}$b¦
255 1¦6¦[[=*=]][[=\=]][[=]=]][[===]][[...]][[:punct:]]¦*\]=.;¦
256 1¦6¦[$\(*\)1]*¦$\()*^¦
257 1¦1¦[\1]¦1¦
258 1¦1¦[\{1,2\}]¦{¦
259 2¦2¦\(*\)*\1*¦a*b*11¦
260 1¦5¦\(a\(b\{1,2\}\)\{1,2\}\)¦abbab¦
261 1¦1¦^\(^\(^a$\)$\)$¦a¦
262 1¦2¦\(a\)\1$¦aa¦
263 1¦3¦ab*¦abb¦
264 1¦4¦ab\{2,4\}¦abbbc¦
265 # 2.8.3.5  BRE Expression Anchoring
266 # GA144
267 1¦1¦^a¦abc¦
268 -1¦-1¦^b¦abc¦
269 -1¦-1¦^[a-zA-Z]¦99Nine¦
270 1¦4¦^[a-zA-Z]¦Nine99¦
271 # GA145(1)
272 1¦2¦\(^a\)\1¦aabc¦
273 -1¦-1¦\(^a\)\1¦^a^abc¦
274 1¦2¦\(^^a\)¦^a¦
275 1¦1¦\(^^\)¦^^¦
276 1¦3¦\(^abc\)¦abcdef¦
277 -1¦-1¦\(^def\)¦abcdef¦
278 ### GA145(2)                    GNU regex implements GA145(1)
279 ##-1¦-1¦\(^a\)\1¦aabc¦
280 ##1¦4¦\(^a\)\1¦^a^abc¦
281 ##-1¦-1¦\(^^a\)¦^a¦
282 ##1¦2¦\(^^\)¦^^¦
283 # GA146
284 3¦3¦a$¦cba¦
285 -1¦-1¦a$¦abc¦
286 5¦7¦[a-z]*$¦99ZZxyz¦
287 -1¦-1¦[a-z]*$¦99ZZxyz99¦
288 3¦3¦$$¦ab$¦
289 -1¦-1¦$$¦$ab¦
290 3¦3¦\$$¦ab$¦
291 # GA147(1)
292 -1¦-1¦\(a$\)\1¦bcaa¦
293 -1¦-1¦\(a$\)\1¦ba$¦
294 -1¦-1¦\(ab$\)¦ab$¦
295 1¦2¦\(ab$\)¦ab¦
296 4¦6¦\(def$\)¦abcdef¦
297 -1¦-1¦\(abc$\)¦abcdef¦
298 ### GA147(2)                    GNU regex implements GA147(1)
299 ##-1¦-1¦\(a$\)\1¦bcaa¦
300 ##2¦5¦\(a$\)\1¦ba$a$¦
301 ##-1¦-1¦\(ab$\)¦ab¦
302 ##1¦3¦\(ab$\)¦ab$¦
303 # GA148
304 0¦0¦^$¦¦
305 1¦3¦^abc$¦abc¦
306 -1¦-1¦^xyz$¦^xyz^¦
307 -1¦-1¦^234$¦^234$¦
308 1¦9¦^[a-zA-Z0-9]*$¦2aA3bB9zZ¦
309 -1¦-1¦^[a-z0-9]*$¦2aA3b#B9zZ¦