Debian Codegraph @

rhino/testsrc/tests/js1_5/extensions/regress-319683.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-319683.js';
7 //-----------------------------------------------------------------------------
8 var BUGNUMBER = 319683;
9 var summary = 'Do not crash in call_enumerate';
10 var actual = 'No Crash';
11 var expect = 'No Crash';
12 printBugNumber(BUGNUMBER);
13 printStatus (summary);
14
15 function crash(){
16 function f(){
17 var x;
18 function g(){
19 x=1; //reference anything here or will not crash.
20 }
21 }
22
23 //apply an object to the __proto__ attribute
24 f.__proto__={};
25
26 //the following call will cause crash
27 f();
28 }
29
30 crash();
31
32 reportCompare(expect, actual, summary);