js/src/tests/ecma/LexicalConventions/7.7.3-2.js

Wed, 31 Dec 2014 06:09:35 +0100

author
Michael Schloh von Bennewitz <michael@schloh.com>
date
Wed, 31 Dec 2014 06:09:35 +0100
changeset 0
6474c204b198
permissions
-rw-r--r--

Cloned upstream origin tor-browser at tor-browser-31.3.0esr-4.5-1-build1
revision ID fc1c9ff7c1b2defdbc039f12214767608f46423f for hacking purpose.

michael@0 1 /* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
michael@0 2 /* This Source Code Form is subject to the terms of the Mozilla Public
michael@0 3 * License, v. 2.0. If a copy of the MPL was not distributed with this
michael@0 4 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
michael@0 5
michael@0 6
michael@0 7 /**
michael@0 8 File Name: 7.7.3-2.js
michael@0 9 ECMA Section: 7.7.3 Numeric Literals
michael@0 10
michael@0 11 Description:
michael@0 12
michael@0 13 This is a regression test for
michael@0 14 http://scopus.mcom.com/bugsplat/show_bug.cgi?id=122884
michael@0 15
michael@0 16 Waldemar's comments:
michael@0 17
michael@0 18 A numeric literal that starts with either '08' or '09' is interpreted as a
michael@0 19 decimal literal; it should be an error instead. (Strictly speaking, according
michael@0 20 to ECMA v1 such literals should be interpreted as two integers -- a zero
michael@0 21 followed by a decimal number whose first digit is 8 or 9, but this is a bug in
michael@0 22 ECMA that will be fixed in v2. In any case, there is no place in the grammar
michael@0 23 where two consecutive numbers would be legal.)
michael@0 24
michael@0 25 Author: christine@netscape.com
michael@0 26 Date: 15 june 1998
michael@0 27
michael@0 28 */
michael@0 29 var SECTION = "7.7.3-2";
michael@0 30 var VERSION = "ECMA_1";
michael@0 31 var TITLE = "Numeric Literals";
michael@0 32 var BUGNUMBER="122884";
michael@0 33
michael@0 34 startTest();
michael@0 35
michael@0 36 writeHeaderToLog( SECTION + " "+ TITLE);
michael@0 37
michael@0 38 new TestCase( SECTION,
michael@0 39 "9",
michael@0 40 9,
michael@0 41 9 );
michael@0 42
michael@0 43 new TestCase( SECTION,
michael@0 44 "09",
michael@0 45 9,
michael@0 46 09 );
michael@0 47
michael@0 48 new TestCase( SECTION,
michael@0 49 "099",
michael@0 50 99,
michael@0 51 099 );
michael@0 52
michael@0 53
michael@0 54 new TestCase( SECTION,
michael@0 55 "077",
michael@0 56 63,
michael@0 57 077 );
michael@0 58
michael@0 59 test();

mercurial