js/src/tests/ecma_2/Exceptions/lexical-022.js

branch
TOR_BUG_3246
changeset 7
129ffea94266
equal deleted inserted replaced
-1:000000000000 0:c7ff85e2e575
1 // |reftest| skip -- obsolete test
2 /* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
3 /* This Source Code Form is subject to the terms of the Mozilla Public
4 * License, v. 2.0. If a copy of the MPL was not distributed with this
5 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
6
7
8 /**
9 File Name: lexical-022
10 Corresponds To 7.4.3-15-n.js
11 ECMA Section: 7.4.3
12
13 Description:
14 The following words are used as keywords in proposed extensions and are
15 therefore reserved to allow for the possibility of future adoption of
16 those extensions.
17
18 FutureReservedWord :: one of
19 case debugger export super
20 catch default extends switch
21 class do finally throw
22 const enum import try
23
24 Author: christine@netscape.com
25 Date: 12 november 1997
26 */
27 var SECTION = "lexical-022.js";
28 var VERSION = "ECMA_1";
29 var TITLE = "Future Reserved Words";
30
31 startTest();
32 writeHeaderToLog( SECTION + " "+ TITLE);
33
34 var result = "Failed";
35 var exception = "No exception thrown";
36 var expect = "Passed";
37
38 try {
39 eval("import = true;");
40 } catch ( e ) {
41 result = expect;
42 exception = e.toString();
43 }
44
45 new TestCase(
46 SECTION,
47 "import = true" +
48 " (threw " + exception +")",
49 expect,
50 result );
51
52 test();
53
54

mercurial