Debian Codegraph @

rhino/testsrc/tests/js1_5/Regress/regress-230216-2.js

raw symbols SCIP
1 /* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
2 /* This Source Code Form is subject to the terms of the Mozilla Public
3 * License, v. 2.0. If a copy of the MPL was not distributed with this
4 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
5
6 var gTestfile = 'regress-230216-2.js';
7 //-----------------------------------------------------------------------------
8 var BUGNUMBER = 230216;
9 var summary = 'check for numerical overflow in regexps in back reference and bounds for {} quantifier';
10 var actual = '';
11 var expect = '';
12 var status = '';
13
14 DESCRIPTION = summary;
15 EXPECTED = 'error';
16
17 printBugNumber(BUGNUMBER);
18 printStatus (summary);
19
20 status = inSection(1) + ' check for overflow in quantifier';
21
22 actual = 'undefined';
23 expect = 'error';
24
25 try
26 {
27 var result = eval('/a{21474836481}/.test("a")');
28 actual = 'no exception thrown';
29 status += ' result: ' + result;
30 }
31 catch(e)
32 {
33 actual = 'error';
34 }
35
36 reportCompare(expect, actual, status);
37