~ubuntu-branches/ubuntu/raring/qtwebkit-source/raring-proposed

« back to all changes in this revision

Viewing changes to Source/JavaScriptCore/tests/mozilla/ecma_3/RegExp/perlstress-002.js

  • Committer: Package Import Robot
  • Author(s): Jonathan Riddell
  • Date: 2013-02-18 14:24:18 UTC
  • Revision ID: package-import@ubuntu.com-20130218142418-eon0jmjg3nj438uy
Tags: upstream-2.3
ImportĀ upstreamĀ versionĀ 2.3

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/* ***** BEGIN LICENSE BLOCK *****
 
2
* Version: NPL 1.1/GPL 2.0/LGPL 2.1
 
3
*
 
4
* The contents of this file are subject to the Netscape Public License
 
5
* Version 1.1 (the "License"); you may not use this file except in
 
6
* compliance with the License. You may obtain a copy of the License at
 
7
* http://www.mozilla.org/NPL/
 
8
*
 
9
* Software distributed under the License is distributed on an "AS IS" basis,
 
10
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
 
11
* for the specific language governing rights and limitations under the
 
12
* License.
 
13
*
 
14
* The Original Code is JavaScript Engine testing utilities.
 
15
*
 
16
* The Initial Developer of the Original Code is Netscape Communications Corp.
 
17
* Portions created by the Initial Developer are Copyright (C) 2002
 
18
* the Initial Developer. All Rights Reserved.
 
19
*
 
20
* Contributor(s): pschwartau@netscape.com, rogerl@netscape.com
 
21
*
 
22
* Alternatively, the contents of this file may be used under the terms of
 
23
* either the GNU General Public License Version 2 or later (the "GPL"), or
 
24
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
 
25
* in which case the provisions of the GPL or the LGPL are applicable instead
 
26
* of those above. If you wish to allow use of your version of this file only
 
27
* under the terms of either the GPL or the LGPL, and not to allow others to
 
28
* use your version of this file under the terms of the NPL, indicate your
 
29
* decision by deleting the provisions above and replace them with the notice
 
30
* and other provisions required by the GPL or the LGPL. If you do not delete
 
31
* the provisions above, a recipient may use your version of this file under
 
32
* the terms of any one of the NPL, the GPL or the LGPL.
 
33
*
 
34
* ***** END LICENSE BLOCK *****
 
35
*
 
36
*
 
37
* Date:    2002-07-07
 
38
* SUMMARY: Testing JS RegExp engine against Perl 5 RegExp engine.
 
39
* Adjust cnLBOUND, cnUBOUND below to restrict which sections are tested.
 
40
*
 
41
* This test was created by running various patterns and strings through the
 
42
* Perl 5 RegExp engine. We saved the results below to test the JS engine.
 
43
*
 
44
* Each of the examples below is a negative test; that is, each produces a
 
45
* null match in Perl. Thus we set |expectedmatch| = |null| in each section.
 
46
*
 
47
* NOTE: ECMA/JS and Perl do differ on certain points. We have either commented
 
48
* out such sections altogether, or modified them to fit what we expect from JS.
 
49
*
 
50
* EXAMPLES:
 
51
*
 
52
* - ECMA does support (?: (?= and (?! operators, but doesn't support (?<  etc.
 
53
*
 
54
* - ECMA doesn't support (?(condition)
 
55
*
 
56
*/
 
57
//-----------------------------------------------------------------------------
 
58
var i = 0;
 
59
var bug = 85721;
 
60
var summary = 'Testing regular expression edge cases';
 
61
var cnSingleSpace = ' ';
 
62
var status = '';
 
63
var statusmessages = new Array();
 
64
var pattern = '';
 
65
var patterns = new Array();
 
66
var string = '';
 
67
var strings = new Array();
 
68
var actualmatch = '';
 
69
var actualmatches = new Array();
 
70
var expectedmatch = '';
 
71
var expectedmatches = new Array();
 
72
var cnLBOUND = 0;
 
73
var cnUBOUND = 1000;
 
74
 
 
75
 
 
76
status = inSection(1);
 
77
pattern = /abc/;
 
78
string = 'xbc';
 
79
actualmatch = string.match(pattern);
 
80
expectedmatch = null;
 
81
addThis();
 
82
 
 
83
status = inSection(2);
 
84
pattern = /abc/;
 
85
string = 'axc';
 
86
actualmatch = string.match(pattern);
 
87
expectedmatch = null;
 
88
addThis();
 
89
 
 
90
status = inSection(3);
 
91
pattern = /abc/;
 
92
string = 'abx';
 
93
actualmatch = string.match(pattern);
 
94
expectedmatch = null;
 
95
addThis();
 
96
 
 
97
status = inSection(4);
 
98
pattern = /ab+bc/;
 
99
string = 'abc';
 
100
actualmatch = string.match(pattern);
 
101
expectedmatch = null;
 
102
addThis();
 
103
 
 
104
status = inSection(5);
 
105
pattern = /ab+bc/;
 
106
string = 'abq';
 
107
actualmatch = string.match(pattern);
 
108
expectedmatch = null;
 
109
addThis();
 
110
 
 
111
status = inSection(6);
 
112
pattern = /ab{1,}bc/;
 
113
string = 'abq';
 
114
actualmatch = string.match(pattern);
 
115
expectedmatch = null;
 
116
addThis();
 
117
 
 
118
status = inSection(7);
 
119
pattern = /ab{4,5}bc/;
 
120
string = 'abbbbc';
 
121
actualmatch = string.match(pattern);
 
122
expectedmatch = null;
 
123
addThis();
 
124
 
 
125
status = inSection(8);
 
126
pattern = /ab?bc/;
 
127
string = 'abbbbc';
 
128
actualmatch = string.match(pattern);
 
129
expectedmatch = null;
 
130
addThis();
 
131
 
 
132
status = inSection(9);
 
133
pattern = /^abc$/;
 
134
string = 'abcc';
 
135
actualmatch = string.match(pattern);
 
136
expectedmatch = null;
 
137
addThis();
 
138
 
 
139
status = inSection(10);
 
140
pattern = /^abc$/;
 
141
string = 'aabc';
 
142
actualmatch = string.match(pattern);
 
143
expectedmatch = null;
 
144
addThis();
 
145
 
 
146
status = inSection(11);
 
147
pattern = /abc$/;
 
148
string = 'aabcd';
 
149
actualmatch = string.match(pattern);
 
150
expectedmatch = null;
 
151
addThis();
 
152
 
 
153
status = inSection(12);
 
154
pattern = /a.*c/;
 
155
string = 'axyzd';
 
156
actualmatch = string.match(pattern);
 
157
expectedmatch = null;
 
158
addThis();
 
159
 
 
160
status = inSection(13);
 
161
pattern = /a[bc]d/;
 
162
string = 'abc';
 
163
actualmatch = string.match(pattern);
 
164
expectedmatch = null;
 
165
addThis();
 
166
 
 
167
status = inSection(14);
 
168
pattern = /a[b-d]e/;
 
169
string = 'abd';
 
170
actualmatch = string.match(pattern);
 
171
expectedmatch = null;
 
172
addThis();
 
173
 
 
174
status = inSection(15);
 
175
pattern = /a[^bc]d/;
 
176
string = 'abd';
 
177
actualmatch = string.match(pattern);
 
178
expectedmatch = null;
 
179
addThis();
 
180
 
 
181
status = inSection(16);
 
182
pattern = /a[^-b]c/;
 
183
string = 'a-c';
 
184
actualmatch = string.match(pattern);
 
185
expectedmatch = null;
 
186
addThis();
 
187
 
 
188
status = inSection(17);
 
189
pattern = /a[^]b]c/;
 
190
string = 'a]c';
 
191
actualmatch = string.match(pattern);
 
192
expectedmatch = null;
 
193
addThis();
 
194
 
 
195
status = inSection(18);
 
196
pattern = /\by\b/;
 
197
string = 'xy';
 
198
actualmatch = string.match(pattern);
 
199
expectedmatch = null;
 
200
addThis();
 
201
 
 
202
status = inSection(19);
 
203
pattern = /\by\b/;
 
204
string = 'yz';
 
205
actualmatch = string.match(pattern);
 
206
expectedmatch = null;
 
207
addThis();
 
208
 
 
209
status = inSection(20);
 
210
pattern = /\by\b/;
 
211
string = 'xyz';
 
212
actualmatch = string.match(pattern);
 
213
expectedmatch = null;
 
214
addThis();
 
215
 
 
216
status = inSection(21);
 
217
pattern = /\Ba\B/;
 
218
string = 'a-';
 
219
actualmatch = string.match(pattern);
 
220
expectedmatch = null;
 
221
addThis();
 
222
 
 
223
status = inSection(22);
 
224
pattern = /\Ba\B/;
 
225
string = '-a';
 
226
actualmatch = string.match(pattern);
 
227
expectedmatch = null;
 
228
addThis();
 
229
 
 
230
status = inSection(23);
 
231
pattern = /\Ba\B/;
 
232
string = '-a-';
 
233
actualmatch = string.match(pattern);
 
234
expectedmatch = null;
 
235
addThis();
 
236
 
 
237
status = inSection(24);
 
238
pattern = /\w/;
 
239
string = '-';
 
240
actualmatch = string.match(pattern);
 
241
expectedmatch = null;
 
242
addThis();
 
243
 
 
244
status = inSection(25);
 
245
pattern = /\W/;
 
246
string = 'a';
 
247
actualmatch = string.match(pattern);
 
248
expectedmatch = null;
 
249
addThis();
 
250
 
 
251
status = inSection(26);
 
252
pattern = /a\sb/;
 
253
string = 'a-b';
 
254
actualmatch = string.match(pattern);
 
255
expectedmatch = null;
 
256
addThis();
 
257
 
 
258
status = inSection(27);
 
259
pattern = /\d/;
 
260
string = '-';
 
261
actualmatch = string.match(pattern);
 
262
expectedmatch = null;
 
263
addThis();
 
264
 
 
265
status = inSection(28);
 
266
pattern = /\D/;
 
267
string = '1';
 
268
actualmatch = string.match(pattern);
 
269
expectedmatch = null;
 
270
addThis();
 
271
 
 
272
status = inSection(29);
 
273
pattern = /[\w]/;
 
274
string = '-';
 
275
actualmatch = string.match(pattern);
 
276
expectedmatch = null;
 
277
addThis();
 
278
 
 
279
status = inSection(30);
 
280
pattern = /[\W]/;
 
281
string = 'a';
 
282
actualmatch = string.match(pattern);
 
283
expectedmatch = null;
 
284
addThis();
 
285
 
 
286
status = inSection(31);
 
287
pattern = /a[\s]b/;
 
288
string = 'a-b';
 
289
actualmatch = string.match(pattern);
 
290
expectedmatch = null;
 
291
addThis();
 
292
 
 
293
status = inSection(32);
 
294
pattern = /[\d]/;
 
295
string = '-';
 
296
actualmatch = string.match(pattern);
 
297
expectedmatch = null;
 
298
addThis();
 
299
 
 
300
status = inSection(33);
 
301
pattern = /[\D]/;
 
302
string = '1';
 
303
actualmatch = string.match(pattern);
 
304
expectedmatch = null;
 
305
addThis();
 
306
 
 
307
status = inSection(34);
 
308
pattern = /$b/;
 
309
string = 'b';
 
310
actualmatch = string.match(pattern);
 
311
expectedmatch = null;
 
312
addThis();
 
313
 
 
314
status = inSection(35);
 
315
pattern = /^(ab|cd)e/;
 
316
string = 'abcde';
 
317
actualmatch = string.match(pattern);
 
318
expectedmatch = null;
 
319
addThis();
 
320
 
 
321
status = inSection(36);
 
322
pattern = /a[bcd]+dcdcde/;
 
323
string = 'adcdcde';
 
324
actualmatch = string.match(pattern);
 
325
expectedmatch = null;
 
326
addThis();
 
327
 
 
328
status = inSection(37);
 
329
pattern = /(bc+d$|ef*g.|h?i(j|k))/;
 
330
string = 'effg';
 
331
actualmatch = string.match(pattern);
 
332
expectedmatch = null;
 
333
addThis();
 
334
 
 
335
status = inSection(38);
 
336
pattern = /(bc+d$|ef*g.|h?i(j|k))/;
 
337
string = 'bcdd';
 
338
actualmatch = string.match(pattern);
 
339
expectedmatch = null;
 
340
addThis();
 
341
 
 
342
status = inSection(39);
 
343
pattern = /[k]/;
 
344
string = 'ab';
 
345
actualmatch = string.match(pattern);
 
346
expectedmatch = null;
 
347
addThis();
 
348
 
 
349
// MODIFIED - ECMA has different rules for paren contents.
 
350
status = inSection(40);
 
351
pattern = /(a)|\1/;
 
352
string = 'x';
 
353
actualmatch = string.match(pattern);
 
354
//expectedmatch = null;
 
355
expectedmatch = Array("", undefined);
 
356
addThis();
 
357
 
 
358
// MODIFIED - ECMA has different rules for paren contents.
 
359
status = inSection(41);
 
360
pattern = /((\3|b)\2(a)x)+/;
 
361
string = 'aaxabxbaxbbx';
 
362
actualmatch = string.match(pattern);
 
363
//expectedmatch = null;
 
364
expectedmatch = Array("ax", "ax", "", "a");
 
365
addThis();
 
366
 
 
367
status = inSection(42);
 
368
pattern = /abc/i;
 
369
string = 'XBC';
 
370
actualmatch = string.match(pattern);
 
371
expectedmatch = null;
 
372
addThis();
 
373
 
 
374
status = inSection(43);
 
375
pattern = /abc/i;
 
376
string = 'AXC';
 
377
actualmatch = string.match(pattern);
 
378
expectedmatch = null;
 
379
addThis();
 
380
 
 
381
status = inSection(44);
 
382
pattern = /abc/i;
 
383
string = 'ABX';
 
384
actualmatch = string.match(pattern);
 
385
expectedmatch = null;
 
386
addThis();
 
387
 
 
388
status = inSection(45);
 
389
pattern = /ab+bc/i;
 
390
string = 'ABC';
 
391
actualmatch = string.match(pattern);
 
392
expectedmatch = null;
 
393
addThis();
 
394
 
 
395
status = inSection(46);
 
396
pattern = /ab+bc/i;
 
397
string = 'ABQ';
 
398
actualmatch = string.match(pattern);
 
399
expectedmatch = null;
 
400
addThis();
 
401
 
 
402
status = inSection(47);
 
403
pattern = /ab{1,}bc/i;
 
404
string = 'ABQ';
 
405
actualmatch = string.match(pattern);
 
406
expectedmatch = null;
 
407
addThis();
 
408
 
 
409
status = inSection(48);
 
410
pattern = /ab{4,5}?bc/i;
 
411
string = 'ABBBBC';
 
412
actualmatch = string.match(pattern);
 
413
expectedmatch = null;
 
414
addThis();
 
415
 
 
416
status = inSection(49);
 
417
pattern = /ab??bc/i;
 
418
string = 'ABBBBC';
 
419
actualmatch = string.match(pattern);
 
420
expectedmatch = null;
 
421
addThis();
 
422
 
 
423
status = inSection(50);
 
424
pattern = /^abc$/i;
 
425
string = 'ABCC';
 
426
actualmatch = string.match(pattern);
 
427
expectedmatch = null;
 
428
addThis();
 
429
 
 
430
status = inSection(51);
 
431
pattern = /^abc$/i;
 
432
string = 'AABC';
 
433
actualmatch = string.match(pattern);
 
434
expectedmatch = null;
 
435
addThis();
 
436
 
 
437
status = inSection(52);
 
438
pattern = /a.*c/i;
 
439
string = 'AXYZD';
 
440
actualmatch = string.match(pattern);
 
441
expectedmatch = null;
 
442
addThis();
 
443
 
 
444
status = inSection(53);
 
445
pattern = /a[bc]d/i;
 
446
string = 'ABC';
 
447
actualmatch = string.match(pattern);
 
448
expectedmatch = null;
 
449
addThis();
 
450
 
 
451
status = inSection(54);
 
452
pattern = /a[b-d]e/i;
 
453
string = 'ABD';
 
454
actualmatch = string.match(pattern);
 
455
expectedmatch = null;
 
456
addThis();
 
457
 
 
458
status = inSection(55);
 
459
pattern = /a[^bc]d/i;
 
460
string = 'ABD';
 
461
actualmatch = string.match(pattern);
 
462
expectedmatch = null;
 
463
addThis();
 
464
 
 
465
status = inSection(56);
 
466
pattern = /a[^-b]c/i;
 
467
string = 'A-C';
 
468
actualmatch = string.match(pattern);
 
469
expectedmatch = null;
 
470
addThis();
 
471
 
 
472
status = inSection(57);
 
473
pattern = /a[^]b]c/i;
 
474
string = 'A]C';
 
475
actualmatch = string.match(pattern);
 
476
expectedmatch = null;
 
477
addThis();
 
478
 
 
479
status = inSection(58);
 
480
pattern = /$b/i;
 
481
string = 'B';
 
482
actualmatch = string.match(pattern);
 
483
expectedmatch = null;
 
484
addThis();
 
485
 
 
486
status = inSection(59);
 
487
pattern = /^(ab|cd)e/i;
 
488
string = 'ABCDE';
 
489
actualmatch = string.match(pattern);
 
490
expectedmatch = null;
 
491
addThis();
 
492
 
 
493
status = inSection(60);
 
494
pattern = /a[bcd]+dcdcde/i;
 
495
string = 'ADCDCDE';
 
496
actualmatch = string.match(pattern);
 
497
expectedmatch = null;
 
498
addThis();
 
499
 
 
500
status = inSection(61);
 
501
pattern = /(bc+d$|ef*g.|h?i(j|k))/i;
 
502
string = 'EFFG';
 
503
actualmatch = string.match(pattern);
 
504
expectedmatch = null;
 
505
addThis();
 
506
 
 
507
status = inSection(62);
 
508
pattern = /(bc+d$|ef*g.|h?i(j|k))/i;
 
509
string = 'BCDD';
 
510
actualmatch = string.match(pattern);
 
511
expectedmatch = null;
 
512
addThis();
 
513
 
 
514
status = inSection(63);
 
515
pattern = /[k]/i;
 
516
string = 'AB';
 
517
actualmatch = string.match(pattern);
 
518
expectedmatch = null;
 
519
addThis();
 
520
 
 
521
status = inSection(64);
 
522
pattern = /^(a\1?){4}$/;
 
523
string = 'aaaaaaaaa';
 
524
actualmatch = string.match(pattern);
 
525
expectedmatch = null;
 
526
addThis();
 
527
 
 
528
status = inSection(65);
 
529
pattern = /^(a\1?){4}$/;
 
530
string = 'aaaaaaaaaaa';
 
531
actualmatch = string.match(pattern);
 
532
expectedmatch = null;
 
533
addThis();
 
534
 
 
535
/* ECMA doesn't support (?(
 
536
status = inSection(66);
 
537
pattern = /^(a(?(1)\1)){4}$/;
 
538
string = 'aaaaaaaaa';
 
539
actualmatch = string.match(pattern);
 
540
expectedmatch = null;
 
541
addThis();
 
542
 
 
543
status = inSection(67);
 
544
pattern = /^(a(?(1)\1)){4}$/;
 
545
string = 'aaaaaaaaaaa';
 
546
actualmatch = string.match(pattern);
 
547
expectedmatch = null;
 
548
addThis();
 
549
*/
 
550
 
 
551
/* ECMA doesn't support (?<
 
552
status = inSection(68);
 
553
pattern = /(?<=a)b/;
 
554
string = 'cb';
 
555
actualmatch = string.match(pattern);
 
556
expectedmatch = null;
 
557
addThis();
 
558
 
 
559
status = inSection(69);
 
560
pattern = /(?<=a)b/;
 
561
string = 'b';
 
562
actualmatch = string.match(pattern);
 
563
expectedmatch = null;
 
564
addThis();
 
565
 
 
566
status = inSection(70);
 
567
pattern = /(?<!c)b/;
 
568
string = 'cb';
 
569
actualmatch = string.match(pattern);
 
570
expectedmatch = null;
 
571
addThis();
 
572
*/
 
573
 
 
574
/* ECMA doesn't support (?(condition)
 
575
status = inSection(71);
 
576
pattern = /(?:(?i)a)b/;
 
577
string = 'aB';
 
578
actualmatch = string.match(pattern);
 
579
expectedmatch = null;
 
580
addThis();
 
581
 
 
582
status = inSection(72);
 
583
pattern = /((?i)a)b/;
 
584
string = 'aB';
 
585
actualmatch = string.match(pattern);
 
586
expectedmatch = null;
 
587
addThis();
 
588
 
 
589
status = inSection(73);
 
590
pattern = /(?i:a)b/;
 
591
string = 'aB';
 
592
actualmatch = string.match(pattern);
 
593
expectedmatch = null;
 
594
addThis();
 
595
 
 
596
status = inSection(74);
 
597
pattern = /((?i:a))b/;
 
598
string = 'aB';
 
599
actualmatch = string.match(pattern);
 
600
expectedmatch = null;
 
601
addThis();
 
602
 
 
603
status = inSection(75);
 
604
pattern = /(?:(?-i)a)b/i;
 
605
string = 'Ab';
 
606
actualmatch = string.match(pattern);
 
607
expectedmatch = null;
 
608
addThis();
 
609
 
 
610
status = inSection(76);
 
611
pattern = /((?-i)a)b/i;
 
612
string = 'Ab';
 
613
actualmatch = string.match(pattern);
 
614
expectedmatch = null;
 
615
addThis();
 
616
 
 
617
status = inSection(77);
 
618
pattern = /(?:(?-i)a)b/i;
 
619
string = 'AB';
 
620
actualmatch = string.match(pattern);
 
621
expectedmatch = null;
 
622
addThis();
 
623
 
 
624
status = inSection(78);
 
625
pattern = /((?-i)a)b/i;
 
626
string = 'AB';
 
627
actualmatch = string.match(pattern);
 
628
expectedmatch = null;
 
629
addThis();
 
630
 
 
631
status = inSection(79);
 
632
pattern = /(?-i:a)b/i;
 
633
string = 'Ab';
 
634
actualmatch = string.match(pattern);
 
635
expectedmatch = null;
 
636
addThis();
 
637
 
 
638
status = inSection(80);
 
639
pattern = /((?-i:a))b/i;
 
640
string = 'Ab';
 
641
actualmatch = string.match(pattern);
 
642
expectedmatch = null;
 
643
addThis();
 
644
 
 
645
status = inSection(81);
 
646
pattern = /(?-i:a)b/i;
 
647
string = 'AB';
 
648
actualmatch = string.match(pattern);
 
649
expectedmatch = null;
 
650
addThis();
 
651
 
 
652
status = inSection(82);
 
653
pattern = /((?-i:a))b/i;
 
654
string = 'AB';
 
655
actualmatch = string.match(pattern);
 
656
expectedmatch = null;
 
657
addThis();
 
658
 
 
659
status = inSection(83);
 
660
pattern = /((?-i:a.))b/i;
 
661
string = 'a\nB';
 
662
actualmatch = string.match(pattern);
 
663
expectedmatch = null;
 
664
addThis();
 
665
 
 
666
status = inSection(84);
 
667
pattern = /((?s-i:a.))b/i;
 
668
string = 'B\nB';
 
669
actualmatch = string.match(pattern);
 
670
expectedmatch = null;
 
671
addThis();
 
672
*/
 
673
 
 
674
/* ECMA doesn't support (?<
 
675
status = inSection(85);
 
676
pattern = /(?<![cd])b/;
 
677
string = 'dbcb';
 
678
actualmatch = string.match(pattern);
 
679
expectedmatch = null;
 
680
addThis();
 
681
 
 
682
status = inSection(86);
 
683
pattern = /(?<!(c|d))b/;
 
684
string = 'dbcb';
 
685
actualmatch = string.match(pattern);
 
686
expectedmatch = null;
 
687
addThis();
 
688
*/
 
689
 
 
690
status = inSection(87);
 
691
pattern = /^(?:a?b?)*$/;
 
692
string = 'a--';
 
693
actualmatch = string.match(pattern);
 
694
expectedmatch = null;
 
695
addThis();
 
696
 
 
697
status = inSection(88);
 
698
pattern = /^b/;
 
699
string = 'a\nb\nc\n';
 
700
actualmatch = string.match(pattern);
 
701
expectedmatch = null;
 
702
addThis();
 
703
 
 
704
status = inSection(89);
 
705
pattern = /()^b/;
 
706
string = 'a\nb\nc\n';
 
707
actualmatch = string.match(pattern);
 
708
expectedmatch = null;
 
709
addThis();
 
710
 
 
711
/* ECMA doesn't support (?(
 
712
status = inSection(90);
 
713
pattern = /(?(1)a|b)/;
 
714
string = 'a';
 
715
actualmatch = string.match(pattern);
 
716
expectedmatch = null;
 
717
addThis();
 
718
 
 
719
status = inSection(91);
 
720
pattern = /(x)?(?(1)a|b)/;
 
721
string = 'a';
 
722
actualmatch = string.match(pattern);
 
723
expectedmatch = null;
 
724
addThis();
 
725
 
 
726
status = inSection(92);
 
727
pattern = /()(?(1)b|a)/;
 
728
string = 'a';
 
729
actualmatch = string.match(pattern);
 
730
expectedmatch = null;
 
731
addThis();
 
732
 
 
733
status = inSection(93);
 
734
pattern = /^(\()?blah(?(1)(\)))$/;
 
735
string = 'blah)';
 
736
actualmatch = string.match(pattern);
 
737
expectedmatch = null;
 
738
addThis();
 
739
 
 
740
status = inSection(94);
 
741
pattern = /^(\()?blah(?(1)(\)))$/;
 
742
string = '(blah';
 
743
actualmatch = string.match(pattern);
 
744
expectedmatch = null;
 
745
addThis();
 
746
 
 
747
status = inSection(95);
 
748
pattern = /^(\(+)?blah(?(1)(\)))$/;
 
749
string = 'blah)';
 
750
actualmatch = string.match(pattern);
 
751
expectedmatch = null;
 
752
addThis();
 
753
 
 
754
status = inSection(96);
 
755
pattern = /^(\(+)?blah(?(1)(\)))$/;
 
756
string = '(blah';
 
757
actualmatch = string.match(pattern);
 
758
expectedmatch = null;
 
759
addThis();
 
760
 
 
761
status = inSection(97);
 
762
pattern = /(?(?{0})a|b)/;
 
763
string = 'a';
 
764
actualmatch = string.match(pattern);
 
765
expectedmatch = null;
 
766
addThis();
 
767
 
 
768
status = inSection(98);
 
769
pattern = /(?(?{1})b|a)/;
 
770
string = 'a';
 
771
actualmatch = string.match(pattern);
 
772
expectedmatch = null;
 
773
addThis();
 
774
 
 
775
status = inSection(99);
 
776
pattern = /(?(?!a)a|b)/;
 
777
string = 'a';
 
778
actualmatch = string.match(pattern);
 
779
expectedmatch = null;
 
780
addThis();
 
781
 
 
782
status = inSection(100);
 
783
pattern = /(?(?=a)b|a)/;
 
784
string = 'a';
 
785
actualmatch = string.match(pattern);
 
786
expectedmatch = null;
 
787
addThis();
 
788
*/
 
789
 
 
790
status = inSection(101);
 
791
pattern = /^(?=(a+?))\1ab/;
 
792
string = 'aaab';
 
793
actualmatch = string.match(pattern);
 
794
expectedmatch = null;
 
795
addThis();
 
796
 
 
797
status = inSection(102);
 
798
pattern = /^(?=(a+?))\1ab/;
 
799
string = 'aaab';
 
800
actualmatch = string.match(pattern);
 
801
expectedmatch = null;
 
802
addThis();
 
803
 
 
804
status = inSection(103);
 
805
pattern = /([\w:]+::)?(\w+)$/;
 
806
string = 'abcd:';
 
807
actualmatch = string.match(pattern);
 
808
expectedmatch = null;
 
809
addThis();
 
810
 
 
811
status = inSection(104);
 
812
pattern = /([\w:]+::)?(\w+)$/;
 
813
string = 'abcd:';
 
814
actualmatch = string.match(pattern);
 
815
expectedmatch = null;
 
816
addThis();
 
817
 
 
818
status = inSection(105);
 
819
pattern = /(>a+)ab/;
 
820
string = 'aaab';
 
821
actualmatch = string.match(pattern);
 
822
expectedmatch = null;
 
823
addThis();
 
824
 
 
825
status = inSection(106);
 
826
pattern = /a\Z/;
 
827
string = 'a\nb\n';
 
828
actualmatch = string.match(pattern);
 
829
expectedmatch = null;
 
830
addThis();
 
831
 
 
832
status = inSection(107);
 
833
pattern = /a\z/;
 
834
string = 'a\nb\n';
 
835
actualmatch = string.match(pattern);
 
836
expectedmatch = null;
 
837
addThis();
 
838
 
 
839
status = inSection(108);
 
840
pattern = /a$/;
 
841
string = 'a\nb\n';
 
842
actualmatch = string.match(pattern);
 
843
expectedmatch = null;
 
844
addThis();
 
845
 
 
846
status = inSection(109);
 
847
pattern = /a\z/;
 
848
string = 'b\na\n';
 
849
actualmatch = string.match(pattern);
 
850
expectedmatch = null;
 
851
addThis();
 
852
 
 
853
status = inSection(110);
 
854
pattern = /a\z/m;
 
855
string = 'a\nb\n';
 
856
actualmatch = string.match(pattern);
 
857
expectedmatch = null;
 
858
addThis();
 
859
 
 
860
status = inSection(111);
 
861
pattern = /a\z/m;
 
862
string = 'b\na\n';
 
863
actualmatch = string.match(pattern);
 
864
expectedmatch = null;
 
865
addThis();
 
866
 
 
867
status = inSection(112);
 
868
pattern = /aa\Z/;
 
869
string = 'aa\nb\n';
 
870
actualmatch = string.match(pattern);
 
871
expectedmatch = null;
 
872
addThis();
 
873
 
 
874
status = inSection(113);
 
875
pattern = /aa\z/;
 
876
string = 'aa\nb\n';
 
877
actualmatch = string.match(pattern);
 
878
expectedmatch = null;
 
879
addThis();
 
880
 
 
881
status = inSection(114);
 
882
pattern = /aa$/;
 
883
string = 'aa\nb\n';
 
884
actualmatch = string.match(pattern);
 
885
expectedmatch = null;
 
886
addThis();
 
887
 
 
888
status = inSection(115);
 
889
pattern = /aa\z/;
 
890
string = 'b\naa\n';
 
891
actualmatch = string.match(pattern);
 
892
expectedmatch = null;
 
893
addThis();
 
894
 
 
895
status = inSection(116);
 
896
pattern = /aa\z/m;
 
897
string = 'aa\nb\n';
 
898
actualmatch = string.match(pattern);
 
899
expectedmatch = null;
 
900
addThis();
 
901
 
 
902
status = inSection(117);
 
903
pattern = /aa\z/m;
 
904
string = 'b\naa\n';
 
905
actualmatch = string.match(pattern);
 
906
expectedmatch = null;
 
907
addThis();
 
908
 
 
909
status = inSection(118);
 
910
pattern = /aa\Z/;
 
911
string = 'ac\nb\n';
 
912
actualmatch = string.match(pattern);
 
913
expectedmatch = null;
 
914
addThis();
 
915
 
 
916
status = inSection(119);
 
917
pattern = /aa\z/;
 
918
string = 'ac\nb\n';
 
919
actualmatch = string.match(pattern);
 
920
expectedmatch = null;
 
921
addThis();
 
922
 
 
923
status = inSection(120);
 
924
pattern = /aa$/;
 
925
string = 'ac\nb\n';
 
926
actualmatch = string.match(pattern);
 
927
expectedmatch = null;
 
928
addThis();
 
929
 
 
930
status = inSection(121);
 
931
pattern = /aa\Z/;
 
932
string = 'b\nac\n';
 
933
actualmatch = string.match(pattern);
 
934
expectedmatch = null;
 
935
addThis();
 
936
 
 
937
status = inSection(122);
 
938
pattern = /aa\z/;
 
939
string = 'b\nac\n';
 
940
actualmatch = string.match(pattern);
 
941
expectedmatch = null;
 
942
addThis();
 
943
 
 
944
status = inSection(123);
 
945
pattern = /aa$/;
 
946
string = 'b\nac\n';
 
947
actualmatch = string.match(pattern);
 
948
expectedmatch = null;
 
949
addThis();
 
950
 
 
951
status = inSection(124);
 
952
pattern = /aa\Z/;
 
953
string = 'b\nac';
 
954
actualmatch = string.match(pattern);
 
955
expectedmatch = null;
 
956
addThis();
 
957
 
 
958
status = inSection(125);
 
959
pattern = /aa\z/;
 
960
string = 'b\nac';
 
961
actualmatch = string.match(pattern);
 
962
expectedmatch = null;
 
963
addThis();
 
964
 
 
965
status = inSection(126);
 
966
pattern = /aa$/;
 
967
string = 'b\nac';
 
968
actualmatch = string.match(pattern);
 
969
expectedmatch = null;
 
970
addThis();
 
971
 
 
972
status = inSection(127);
 
973
pattern = /aa\Z/m;
 
974
string = 'ac\nb\n';
 
975
actualmatch = string.match(pattern);
 
976
expectedmatch = null;
 
977
addThis();
 
978
 
 
979
status = inSection(128);
 
980
pattern = /aa\z/m;
 
981
string = 'ac\nb\n';
 
982
actualmatch = string.match(pattern);
 
983
expectedmatch = null;
 
984
addThis();
 
985
 
 
986
status = inSection(129);
 
987
pattern = /aa$/m;
 
988
string = 'ac\nb\n';
 
989
actualmatch = string.match(pattern);
 
990
expectedmatch = null;
 
991
addThis();
 
992
 
 
993
status = inSection(130);
 
994
pattern = /aa\Z/m;
 
995
string = 'b\nac\n';
 
996
actualmatch = string.match(pattern);
 
997
expectedmatch = null;
 
998
addThis();
 
999
 
 
1000
status = inSection(131);
 
1001
pattern = /aa\z/m;
 
1002
string = 'b\nac\n';
 
1003
actualmatch = string.match(pattern);
 
1004
expectedmatch = null;
 
1005
addThis();
 
1006
 
 
1007
status = inSection(132);
 
1008
pattern = /aa$/m;
 
1009
string = 'b\nac\n';
 
1010
actualmatch = string.match(pattern);
 
1011
expectedmatch = null;
 
1012
addThis();
 
1013
 
 
1014
status = inSection(133);
 
1015
pattern = /aa\Z/m;
 
1016
string = 'b\nac';
 
1017
actualmatch = string.match(pattern);
 
1018
expectedmatch = null;
 
1019
addThis();
 
1020
 
 
1021
status = inSection(134);
 
1022
pattern = /aa\z/m;
 
1023
string = 'b\nac';
 
1024
actualmatch = string.match(pattern);
 
1025
expectedmatch = null;
 
1026
addThis();
 
1027
 
 
1028
status = inSection(135);
 
1029
pattern = /aa$/m;
 
1030
string = 'b\nac';
 
1031
actualmatch = string.match(pattern);
 
1032
expectedmatch = null;
 
1033
addThis();
 
1034
 
 
1035
status = inSection(136);
 
1036
pattern = /aa\Z/;
 
1037
string = 'ca\nb\n';
 
1038
actualmatch = string.match(pattern);
 
1039
expectedmatch = null;
 
1040
addThis();
 
1041
 
 
1042
status = inSection(137);
 
1043
pattern = /aa\z/;
 
1044
string = 'ca\nb\n';
 
1045
actualmatch = string.match(pattern);
 
1046
expectedmatch = null;
 
1047
addThis();
 
1048
 
 
1049
status = inSection(138);
 
1050
pattern = /aa$/;
 
1051
string = 'ca\nb\n';
 
1052
actualmatch = string.match(pattern);
 
1053
expectedmatch = null;
 
1054
addThis();
 
1055
 
 
1056
status = inSection(139);
 
1057
pattern = /aa\Z/;
 
1058
string = 'b\nca\n';
 
1059
actualmatch = string.match(pattern);
 
1060
expectedmatch = null;
 
1061
addThis();
 
1062
 
 
1063
status = inSection(140);
 
1064
pattern = /aa\z/;
 
1065
string = 'b\nca\n';
 
1066
actualmatch = string.match(pattern);
 
1067
expectedmatch = null;
 
1068
addThis();
 
1069
 
 
1070
status = inSection(141);
 
1071
pattern = /aa$/;
 
1072
string = 'b\nca\n';
 
1073
actualmatch = string.match(pattern);
 
1074
expectedmatch = null;
 
1075
addThis();
 
1076
 
 
1077
status = inSection(142);
 
1078
pattern = /aa\Z/;
 
1079
string = 'b\nca';
 
1080
actualmatch = string.match(pattern);
 
1081
expectedmatch = null;
 
1082
addThis();
 
1083
 
 
1084
status = inSection(143);
 
1085
pattern = /aa\z/;
 
1086
string = 'b\nca';
 
1087
actualmatch = string.match(pattern);
 
1088
expectedmatch = null;
 
1089
addThis();
 
1090
 
 
1091
status = inSection(144);
 
1092
pattern = /aa$/;
 
1093
string = 'b\nca';
 
1094
actualmatch = string.match(pattern);
 
1095
expectedmatch = null;
 
1096
addThis();
 
1097
 
 
1098
status = inSection(145);
 
1099
pattern = /aa\Z/m;
 
1100
string = 'ca\nb\n';
 
1101
actualmatch = string.match(pattern);
 
1102
expectedmatch = null;
 
1103
addThis();
 
1104
 
 
1105
status = inSection(146);
 
1106
pattern = /aa\z/m;
 
1107
string = 'ca\nb\n';
 
1108
actualmatch = string.match(pattern);
 
1109
expectedmatch = null;
 
1110
addThis();
 
1111
 
 
1112
status = inSection(147);
 
1113
pattern = /aa$/m;
 
1114
string = 'ca\nb\n';
 
1115
actualmatch = string.match(pattern);
 
1116
expectedmatch = null;
 
1117
addThis();
 
1118
 
 
1119
status = inSection(148);
 
1120
pattern = /aa\Z/m;
 
1121
string = 'b\nca\n';
 
1122
actualmatch = string.match(pattern);
 
1123
expectedmatch = null;
 
1124
addThis();
 
1125
 
 
1126
status = inSection(149);
 
1127
pattern = /aa\z/m;
 
1128
string = 'b\nca\n';
 
1129
actualmatch = string.match(pattern);
 
1130
expectedmatch = null;
 
1131
addThis();
 
1132
 
 
1133
status = inSection(150);
 
1134
pattern = /aa$/m;
 
1135
string = 'b\nca\n';
 
1136
actualmatch = string.match(pattern);
 
1137
expectedmatch = null;
 
1138
addThis();
 
1139
 
 
1140
status = inSection(151);
 
1141
pattern = /aa\Z/m;
 
1142
string = 'b\nca';
 
1143
actualmatch = string.match(pattern);
 
1144
expectedmatch = null;
 
1145
addThis();
 
1146
 
 
1147
status = inSection(152);
 
1148
pattern = /aa\z/m;
 
1149
string = 'b\nca';
 
1150
actualmatch = string.match(pattern);
 
1151
expectedmatch = null;
 
1152
addThis();
 
1153
 
 
1154
status = inSection(153);
 
1155
pattern = /aa$/m;
 
1156
string = 'b\nca';
 
1157
actualmatch = string.match(pattern);
 
1158
expectedmatch = null;
 
1159
addThis();
 
1160
 
 
1161
status = inSection(154);
 
1162
pattern = /ab\Z/;
 
1163
string = 'ab\nb\n';
 
1164
actualmatch = string.match(pattern);
 
1165
expectedmatch = null;
 
1166
addThis();
 
1167
 
 
1168
status = inSection(155);
 
1169
pattern = /ab\z/;
 
1170
string = 'ab\nb\n';
 
1171
actualmatch = string.match(pattern);
 
1172
expectedmatch = null;
 
1173
addThis();
 
1174
 
 
1175
status = inSection(156);
 
1176
pattern = /ab$/;
 
1177
string = 'ab\nb\n';
 
1178
actualmatch = string.match(pattern);
 
1179
expectedmatch = null;
 
1180
addThis();
 
1181
 
 
1182
status = inSection(157);
 
1183
pattern = /ab\z/;
 
1184
string = 'b\nab\n';
 
1185
actualmatch = string.match(pattern);
 
1186
expectedmatch = null;
 
1187
addThis();
 
1188
 
 
1189
status = inSection(158);
 
1190
pattern = /ab\z/m;
 
1191
string = 'ab\nb\n';
 
1192
actualmatch = string.match(pattern);
 
1193
expectedmatch = null;
 
1194
addThis();
 
1195
 
 
1196
status = inSection(159);
 
1197
pattern = /ab\z/m;
 
1198
string = 'b\nab\n';
 
1199
actualmatch = string.match(pattern);
 
1200
expectedmatch = null;
 
1201
addThis();
 
1202
 
 
1203
status = inSection(160);
 
1204
pattern = /ab\Z/;
 
1205
string = 'ac\nb\n';
 
1206
actualmatch = string.match(pattern);
 
1207
expectedmatch = null;
 
1208
addThis();
 
1209
 
 
1210
status = inSection(161);
 
1211
pattern = /ab\z/;
 
1212
string = 'ac\nb\n';
 
1213
actualmatch = string.match(pattern);
 
1214
expectedmatch = null;
 
1215
addThis();
 
1216
 
 
1217
status = inSection(162);
 
1218
pattern = /ab$/;
 
1219
string = 'ac\nb\n';
 
1220
actualmatch = string.match(pattern);
 
1221
expectedmatch = null;
 
1222
addThis();
 
1223
 
 
1224
status = inSection(163);
 
1225
pattern = /ab\Z/;
 
1226
string = 'b\nac\n';
 
1227
actualmatch = string.match(pattern);
 
1228
expectedmatch = null;
 
1229
addThis();
 
1230
 
 
1231
status = inSection(164);
 
1232
pattern = /ab\z/;
 
1233
string = 'b\nac\n';
 
1234
actualmatch = string.match(pattern);
 
1235
expectedmatch = null;
 
1236
addThis();
 
1237
 
 
1238
status = inSection(165);
 
1239
pattern = /ab$/;
 
1240
string = 'b\nac\n';
 
1241
actualmatch = string.match(pattern);
 
1242
expectedmatch = null;
 
1243
addThis();
 
1244
 
 
1245
status = inSection(166);
 
1246
pattern = /ab\Z/;
 
1247
string = 'b\nac';
 
1248
actualmatch = string.match(pattern);
 
1249
expectedmatch = null;
 
1250
addThis();
 
1251
 
 
1252
status = inSection(167);
 
1253
pattern = /ab\z/;
 
1254
string = 'b\nac';
 
1255
actualmatch = string.match(pattern);
 
1256
expectedmatch = null;
 
1257
addThis();
 
1258
 
 
1259
status = inSection(168);
 
1260
pattern = /ab$/;
 
1261
string = 'b\nac';
 
1262
actualmatch = string.match(pattern);
 
1263
expectedmatch = null;
 
1264
addThis();
 
1265
 
 
1266
status = inSection(169);
 
1267
pattern = /ab\Z/m;
 
1268
string = 'ac\nb\n';
 
1269
actualmatch = string.match(pattern);
 
1270
expectedmatch = null;
 
1271
addThis();
 
1272
 
 
1273
status = inSection(170);
 
1274
pattern = /ab\z/m;
 
1275
string = 'ac\nb\n';
 
1276
actualmatch = string.match(pattern);
 
1277
expectedmatch = null;
 
1278
addThis();
 
1279
 
 
1280
status = inSection(171);
 
1281
pattern = /ab$/m;
 
1282
string = 'ac\nb\n';
 
1283
actualmatch = string.match(pattern);
 
1284
expectedmatch = null;
 
1285
addThis();
 
1286
 
 
1287
status = inSection(172);
 
1288
pattern = /ab\Z/m;
 
1289
string = 'b\nac\n';
 
1290
actualmatch = string.match(pattern);
 
1291
expectedmatch = null;
 
1292
addThis();
 
1293
 
 
1294
status = inSection(173);
 
1295
pattern = /ab\z/m;
 
1296
string = 'b\nac\n';
 
1297
actualmatch = string.match(pattern);
 
1298
expectedmatch = null;
 
1299
addThis();
 
1300
 
 
1301
status = inSection(174);
 
1302
pattern = /ab$/m;
 
1303
string = 'b\nac\n';
 
1304
actualmatch = string.match(pattern);
 
1305
expectedmatch = null;
 
1306
addThis();
 
1307
 
 
1308
status = inSection(175);
 
1309
pattern = /ab\Z/m;
 
1310
string = 'b\nac';
 
1311
actualmatch = string.match(pattern);
 
1312
expectedmatch = null;
 
1313
addThis();
 
1314
 
 
1315
status = inSection(176);
 
1316
pattern = /ab\z/m;
 
1317
string = 'b\nac';
 
1318
actualmatch = string.match(pattern);
 
1319
expectedmatch = null;
 
1320
addThis();
 
1321
 
 
1322
status = inSection(177);
 
1323
pattern = /ab$/m;
 
1324
string = 'b\nac';
 
1325
actualmatch = string.match(pattern);
 
1326
expectedmatch = null;
 
1327
addThis();
 
1328
 
 
1329
status = inSection(178);
 
1330
pattern = /ab\Z/;
 
1331
string = 'ca\nb\n';
 
1332
actualmatch = string.match(pattern);
 
1333
expectedmatch = null;
 
1334
addThis();
 
1335
 
 
1336
status = inSection(179);
 
1337
pattern = /ab\z/;
 
1338
string = 'ca\nb\n';
 
1339
actualmatch = string.match(pattern);
 
1340
expectedmatch = null;
 
1341
addThis();
 
1342
 
 
1343
status = inSection(180);
 
1344
pattern = /ab$/;
 
1345
string = 'ca\nb\n';
 
1346
actualmatch = string.match(pattern);
 
1347
expectedmatch = null;
 
1348
addThis();
 
1349
 
 
1350
status = inSection(181);
 
1351
pattern = /ab\Z/;
 
1352
string = 'b\nca\n';
 
1353
actualmatch = string.match(pattern);
 
1354
expectedmatch = null;
 
1355
addThis();
 
1356
 
 
1357
status = inSection(182);
 
1358
pattern = /ab\z/;
 
1359
string = 'b\nca\n';
 
1360
actualmatch = string.match(pattern);
 
1361
expectedmatch = null;
 
1362
addThis();
 
1363
 
 
1364
status = inSection(183);
 
1365
pattern = /ab$/;
 
1366
string = 'b\nca\n';
 
1367
actualmatch = string.match(pattern);
 
1368
expectedmatch = null;
 
1369
addThis();
 
1370
 
 
1371
status = inSection(184);
 
1372
pattern = /ab\Z/;
 
1373
string = 'b\nca';
 
1374
actualmatch = string.match(pattern);
 
1375
expectedmatch = null;
 
1376
addThis();
 
1377
 
 
1378
status = inSection(185);
 
1379
pattern = /ab\z/;
 
1380
string = 'b\nca';
 
1381
actualmatch = string.match(pattern);
 
1382
expectedmatch = null;
 
1383
addThis();
 
1384
 
 
1385
status = inSection(186);
 
1386
pattern = /ab$/;
 
1387
string = 'b\nca';
 
1388
actualmatch = string.match(pattern);
 
1389
expectedmatch = null;
 
1390
addThis();
 
1391
 
 
1392
status = inSection(187);
 
1393
pattern = /ab\Z/m;
 
1394
string = 'ca\nb\n';
 
1395
actualmatch = string.match(pattern);
 
1396
expectedmatch = null;
 
1397
addThis();
 
1398
 
 
1399
status = inSection(188);
 
1400
pattern = /ab\z/m;
 
1401
string = 'ca\nb\n';
 
1402
actualmatch = string.match(pattern);
 
1403
expectedmatch = null;
 
1404
addThis();
 
1405
 
 
1406
status = inSection(189);
 
1407
pattern = /ab$/m;
 
1408
string = 'ca\nb\n';
 
1409
actualmatch = string.match(pattern);
 
1410
expectedmatch = null;
 
1411
addThis();
 
1412
 
 
1413
status = inSection(190);
 
1414
pattern = /ab\Z/m;
 
1415
string = 'b\nca\n';
 
1416
actualmatch = string.match(pattern);
 
1417
expectedmatch = null;
 
1418
addThis();
 
1419
 
 
1420
status = inSection(191);
 
1421
pattern = /ab\z/m;
 
1422
string = 'b\nca\n';
 
1423
actualmatch = string.match(pattern);
 
1424
expectedmatch = null;
 
1425
addThis();
 
1426
 
 
1427
status = inSection(192);
 
1428
pattern = /ab$/m;
 
1429
string = 'b\nca\n';
 
1430
actualmatch = string.match(pattern);
 
1431
expectedmatch = null;
 
1432
addThis();
 
1433
 
 
1434
status = inSection(193);
 
1435
pattern = /ab\Z/m;
 
1436
string = 'b\nca';
 
1437
actualmatch = string.match(pattern);
 
1438
expectedmatch = null;
 
1439
addThis();
 
1440
 
 
1441
status = inSection(194);
 
1442
pattern = /ab\z/m;
 
1443
string = 'b\nca';
 
1444
actualmatch = string.match(pattern);
 
1445
expectedmatch = null;
 
1446
addThis();
 
1447
 
 
1448
status = inSection(195);
 
1449
pattern = /ab$/m;
 
1450
string = 'b\nca';
 
1451
actualmatch = string.match(pattern);
 
1452
expectedmatch = null;
 
1453
addThis();
 
1454
 
 
1455
status = inSection(196);
 
1456
pattern = /abb\Z/;
 
1457
string = 'abb\nb\n';
 
1458
actualmatch = string.match(pattern);
 
1459
expectedmatch = null;
 
1460
addThis();
 
1461
 
 
1462
status = inSection(197);
 
1463
pattern = /abb\z/;
 
1464
string = 'abb\nb\n';
 
1465
actualmatch = string.match(pattern);
 
1466
expectedmatch = null;
 
1467
addThis();
 
1468
 
 
1469
status = inSection(198);
 
1470
pattern = /abb$/;
 
1471
string = 'abb\nb\n';
 
1472
actualmatch = string.match(pattern);
 
1473
expectedmatch = null;
 
1474
addThis();
 
1475
 
 
1476
status = inSection(199);
 
1477
pattern = /abb\z/;
 
1478
string = 'b\nabb\n';
 
1479
actualmatch = string.match(pattern);
 
1480
expectedmatch = null;
 
1481
addThis();
 
1482
 
 
1483
status = inSection(200);
 
1484
pattern = /abb\z/m;
 
1485
string = 'abb\nb\n';
 
1486
actualmatch = string.match(pattern);
 
1487
expectedmatch = null;
 
1488
addThis();
 
1489
 
 
1490
status = inSection(201);
 
1491
pattern = /abb\z/m;
 
1492
string = 'b\nabb\n';
 
1493
actualmatch = string.match(pattern);
 
1494
expectedmatch = null;
 
1495
addThis();
 
1496
 
 
1497
status = inSection(202);
 
1498
pattern = /abb\Z/;
 
1499
string = 'ac\nb\n';
 
1500
actualmatch = string.match(pattern);
 
1501
expectedmatch = null;
 
1502
addThis();
 
1503
 
 
1504
status = inSection(203);
 
1505
pattern = /abb\z/;
 
1506
string = 'ac\nb\n';
 
1507
actualmatch = string.match(pattern);
 
1508
expectedmatch = null;
 
1509
addThis();
 
1510
 
 
1511
status = inSection(204);
 
1512
pattern = /abb$/;
 
1513
string = 'ac\nb\n';
 
1514
actualmatch = string.match(pattern);
 
1515
expectedmatch = null;
 
1516
addThis();
 
1517
 
 
1518
status = inSection(205);
 
1519
pattern = /abb\Z/;
 
1520
string = 'b\nac\n';
 
1521
actualmatch = string.match(pattern);
 
1522
expectedmatch = null;
 
1523
addThis();
 
1524
 
 
1525
status = inSection(206);
 
1526
pattern = /abb\z/;
 
1527
string = 'b\nac\n';
 
1528
actualmatch = string.match(pattern);
 
1529
expectedmatch = null;
 
1530
addThis();
 
1531
 
 
1532
status = inSection(207);
 
1533
pattern = /abb$/;
 
1534
string = 'b\nac\n';
 
1535
actualmatch = string.match(pattern);
 
1536
expectedmatch = null;
 
1537
addThis();
 
1538
 
 
1539
status = inSection(208);
 
1540
pattern = /abb\Z/;
 
1541
string = 'b\nac';
 
1542
actualmatch = string.match(pattern);
 
1543
expectedmatch = null;
 
1544
addThis();
 
1545
 
 
1546
status = inSection(209);
 
1547
pattern = /abb\z/;
 
1548
string = 'b\nac';
 
1549
actualmatch = string.match(pattern);
 
1550
expectedmatch = null;
 
1551
addThis();
 
1552
 
 
1553
status = inSection(210);
 
1554
pattern = /abb$/;
 
1555
string = 'b\nac';
 
1556
actualmatch = string.match(pattern);
 
1557
expectedmatch = null;
 
1558
addThis();
 
1559
 
 
1560
status = inSection(211);
 
1561
pattern = /abb\Z/m;
 
1562
string = 'ac\nb\n';
 
1563
actualmatch = string.match(pattern);
 
1564
expectedmatch = null;
 
1565
addThis();
 
1566
 
 
1567
status = inSection(212);
 
1568
pattern = /abb\z/m;
 
1569
string = 'ac\nb\n';
 
1570
actualmatch = string.match(pattern);
 
1571
expectedmatch = null;
 
1572
addThis();
 
1573
 
 
1574
status = inSection(213);
 
1575
pattern = /abb$/m;
 
1576
string = 'ac\nb\n';
 
1577
actualmatch = string.match(pattern);
 
1578
expectedmatch = null;
 
1579
addThis();
 
1580
 
 
1581
status = inSection(214);
 
1582
pattern = /abb\Z/m;
 
1583
string = 'b\nac\n';
 
1584
actualmatch = string.match(pattern);
 
1585
expectedmatch = null;
 
1586
addThis();
 
1587
 
 
1588
status = inSection(215);
 
1589
pattern = /abb\z/m;
 
1590
string = 'b\nac\n';
 
1591
actualmatch = string.match(pattern);
 
1592
expectedmatch = null;
 
1593
addThis();
 
1594
 
 
1595
status = inSection(216);
 
1596
pattern = /abb$/m;
 
1597
string = 'b\nac\n';
 
1598
actualmatch = string.match(pattern);
 
1599
expectedmatch = null;
 
1600
addThis();
 
1601
 
 
1602
status = inSection(217);
 
1603
pattern = /abb\Z/m;
 
1604
string = 'b\nac';
 
1605
actualmatch = string.match(pattern);
 
1606
expectedmatch = null;
 
1607
addThis();
 
1608
 
 
1609
status = inSection(218);
 
1610
pattern = /abb\z/m;
 
1611
string = 'b\nac';
 
1612
actualmatch = string.match(pattern);
 
1613
expectedmatch = null;
 
1614
addThis();
 
1615
 
 
1616
status = inSection(219);
 
1617
pattern = /abb$/m;
 
1618
string = 'b\nac';
 
1619
actualmatch = string.match(pattern);
 
1620
expectedmatch = null;
 
1621
addThis();
 
1622
 
 
1623
status = inSection(220);
 
1624
pattern = /abb\Z/;
 
1625
string = 'ca\nb\n';
 
1626
actualmatch = string.match(pattern);
 
1627
expectedmatch = null;
 
1628
addThis();
 
1629
 
 
1630
status = inSection(221);
 
1631
pattern = /abb\z/;
 
1632
string = 'ca\nb\n';
 
1633
actualmatch = string.match(pattern);
 
1634
expectedmatch = null;
 
1635
addThis();
 
1636
 
 
1637
status = inSection(222);
 
1638
pattern = /abb$/;
 
1639
string = 'ca\nb\n';
 
1640
actualmatch = string.match(pattern);
 
1641
expectedmatch = null;
 
1642
addThis();
 
1643
 
 
1644
status = inSection(223);
 
1645
pattern = /abb\Z/;
 
1646
string = 'b\nca\n';
 
1647
actualmatch = string.match(pattern);
 
1648
expectedmatch = null;
 
1649
addThis();
 
1650
 
 
1651
status = inSection(224);
 
1652
pattern = /abb\z/;
 
1653
string = 'b\nca\n';
 
1654
actualmatch = string.match(pattern);
 
1655
expectedmatch = null;
 
1656
addThis();
 
1657
 
 
1658
status = inSection(225);
 
1659
pattern = /abb$/;
 
1660
string = 'b\nca\n';
 
1661
actualmatch = string.match(pattern);
 
1662
expectedmatch = null;
 
1663
addThis();
 
1664
 
 
1665
status = inSection(226);
 
1666
pattern = /abb\Z/;
 
1667
string = 'b\nca';
 
1668
actualmatch = string.match(pattern);
 
1669
expectedmatch = null;
 
1670
addThis();
 
1671
 
 
1672
status = inSection(227);
 
1673
pattern = /abb\z/;
 
1674
string = 'b\nca';
 
1675
actualmatch = string.match(pattern);
 
1676
expectedmatch = null;
 
1677
addThis();
 
1678
 
 
1679
status = inSection(228);
 
1680
pattern = /abb$/;
 
1681
string = 'b\nca';
 
1682
actualmatch = string.match(pattern);
 
1683
expectedmatch = null;
 
1684
addThis();
 
1685
 
 
1686
status = inSection(229);
 
1687
pattern = /abb\Z/m;
 
1688
string = 'ca\nb\n';
 
1689
actualmatch = string.match(pattern);
 
1690
expectedmatch = null;
 
1691
addThis();
 
1692
 
 
1693
status = inSection(230);
 
1694
pattern = /abb\z/m;
 
1695
string = 'ca\nb\n';
 
1696
actualmatch = string.match(pattern);
 
1697
expectedmatch = null;
 
1698
addThis();
 
1699
 
 
1700
status = inSection(231);
 
1701
pattern = /abb$/m;
 
1702
string = 'ca\nb\n';
 
1703
actualmatch = string.match(pattern);
 
1704
expectedmatch = null;
 
1705
addThis();
 
1706
 
 
1707
status = inSection(232);
 
1708
pattern = /abb\Z/m;
 
1709
string = 'b\nca\n';
 
1710
actualmatch = string.match(pattern);
 
1711
expectedmatch = null;
 
1712
addThis();
 
1713
 
 
1714
status = inSection(233);
 
1715
pattern = /abb\z/m;
 
1716
string = 'b\nca\n';
 
1717
actualmatch = string.match(pattern);
 
1718
expectedmatch = null;
 
1719
addThis();
 
1720
 
 
1721
status = inSection(234);
 
1722
pattern = /abb$/m;
 
1723
string = 'b\nca\n';
 
1724
actualmatch = string.match(pattern);
 
1725
expectedmatch = null;
 
1726
addThis();
 
1727
 
 
1728
status = inSection(235);
 
1729
pattern = /abb\Z/m;
 
1730
string = 'b\nca';
 
1731
actualmatch = string.match(pattern);
 
1732
expectedmatch = null;
 
1733
addThis();
 
1734
 
 
1735
status = inSection(236);
 
1736
pattern = /abb\z/m;
 
1737
string = 'b\nca';
 
1738
actualmatch = string.match(pattern);
 
1739
expectedmatch = null;
 
1740
addThis();
 
1741
 
 
1742
status = inSection(237);
 
1743
pattern = /abb$/m;
 
1744
string = 'b\nca';
 
1745
actualmatch = string.match(pattern);
 
1746
expectedmatch = null;
 
1747
addThis();
 
1748
 
 
1749
status = inSection(238);
 
1750
pattern = /a*abc?xyz+pqr{3}ab{2,}xy{4,5}pq{0,6}AB{0,}zz/;
 
1751
string = 'x';
 
1752
actualmatch = string.match(pattern);
 
1753
expectedmatch = null;
 
1754
addThis();
 
1755
 
 
1756
status = inSection(239);
 
1757
pattern = /\GX.*X/;
 
1758
string = 'aaaXbX';
 
1759
actualmatch = string.match(pattern);
 
1760
expectedmatch = null;
 
1761
addThis();
 
1762
 
 
1763
status = inSection(240);
 
1764
pattern = /\.c(pp|xx|c)?$/i;
 
1765
string = 'Changes';
 
1766
actualmatch = string.match(pattern);
 
1767
expectedmatch = null;
 
1768
addThis();
 
1769
 
 
1770
status = inSection(241);
 
1771
pattern = /^([a-z]:)/;
 
1772
string = 'C:/';
 
1773
actualmatch = string.match(pattern);
 
1774
expectedmatch = null;
 
1775
addThis();
 
1776
 
 
1777
status = inSection(242);
 
1778
pattern = /(\w)?(abc)\1b/;
 
1779
string = 'abcab';
 
1780
actualmatch = string.match(pattern);
 
1781
expectedmatch = null;
 
1782
addThis();
 
1783
 
 
1784
/* ECMA doesn't support (?(
 
1785
status = inSection(243);
 
1786
pattern = /^(a)?(?(1)a|b)+$/;
 
1787
string = 'a';
 
1788
actualmatch = string.match(pattern);
 
1789
expectedmatch = null;
 
1790
addThis();
 
1791
*/
 
1792
 
 
1793
 
 
1794
 
 
1795
//-----------------------------------------------------------------------------
 
1796
test();
 
1797
//-----------------------------------------------------------------------------
 
1798
 
 
1799
 
 
1800
 
 
1801
function addThis()
 
1802
{
 
1803
  if(omitCurrentSection())
 
1804
    return;
 
1805
 
 
1806
  statusmessages[i] = status;
 
1807
  patterns[i] = pattern;
 
1808
  strings[i] = string;
 
1809
  actualmatches[i] = actualmatch;
 
1810
  expectedmatches[i] = expectedmatch;
 
1811
  i++;
 
1812
}
 
1813
 
 
1814
 
 
1815
function omitCurrentSection()
 
1816
{
 
1817
  try
 
1818
  {
 
1819
    // current section number is in global status variable
 
1820
    var n = status.match(/(\d+)/)[1];
 
1821
    return ((n < cnLBOUND) || (n > cnUBOUND));
 
1822
  }
 
1823
  catch(e)
 
1824
  {
 
1825
    return false;
 
1826
  }
 
1827
}
 
1828
 
 
1829
 
 
1830
function test()
 
1831
{
 
1832
  enterFunc ('test');
 
1833
  printBugNumber (bug);
 
1834
  printStatus (summary);
 
1835
  testRegExp(statusmessages, patterns, strings, actualmatches, expectedmatches);
 
1836
  exitFunc ('test');
 
1837
}