Debian Codegraph @

rhino/testsrc/tests/js1_5/Function/regress-292215.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-292215.js';
7 //-----------------------------------------------------------------------------
8 var BUGNUMBER = 292215;
9 var summary = 'Set arguments';
10 var actual = '';
11 var expect = '00012';
12
13 printBugNumber(BUGNUMBER);
14 printStatus (summary);
15
16
17 function zeroArguments () {
18 arguments[1] = '0';
19 actual += arguments[1];
20 }
21
22 function oneArgument (x) {
23 arguments[1] = '1';
24 actual += arguments[1];
25 }
26
27 function twoArguments (x,y) {
28 arguments[1] = '2';
29 actual += arguments[1];
30 }
31
32 zeroArguments();
33 zeroArguments(1);
34 zeroArguments('a', 'b');
35 oneArgument();
36 twoArguments();
37
38 reportCompare(expect, actual, summary);