Debian Codegraph @

rhino/testsrc/tests/ecma_2/Exceptions/lexical-041.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 gTestfile = 'lexical-041.js';
7
8 /**
9 File Name: lexical-041.js
10 Corresponds To: 7.5-8-n.js
11 ECMA Section: 7.5 Identifiers
12 Description: Identifiers are of unlimited length
13 - can contain letters, a decimal digit, _, or $
14 - the first character cannot be a decimal digit
15 - identifiers are case sensitive
16
17 Author: [email protected]
18 Date: 11 september 1997
19 */
20 var SECTION = "lexical-041";
21 var VERSION = "ECMA_1";
22 var TITLE = "Identifiers";
23
24 startTest();
25 writeHeaderToLog( SECTION + " "+ TITLE);
26 startTest();
27 writeHeaderToLog( SECTION + " "+ TITLE);
28
29 var result = "Failed";
30 var exception = "No exception thrown";
31 var expect = "Passed";
32
33 try {
34 eval("var @abc;");
35 } catch ( e ) {
36 result = expect;
37 exception = e.toString();
38 }
39
40 new TestCase(
41 SECTION,
42 "var @abc" +
43 " (threw " + exception +")",
44 expect,
45 result );
46
47 test();
48
49