js/src/tests/ecma_5/strict/B.1.1.js

Thu, 15 Jan 2015 15:55:04 +0100

author
Michael Schloh von Bennewitz <michael@schloh.com>
date
Thu, 15 Jan 2015 15:55:04 +0100
branch
TOR_BUG_9701
changeset 9
a63d609f5ebe
permissions
-rw-r--r--

Back out 97036ab72558 which inappropriately compared turds to third parties.

     1 /* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
     3 /*
     4  * Any copyright is dedicated to the Public Domain.
     5  * http://creativecommons.org/licenses/publicdomain/
     6  */
     8 /* Octal integer literal at top level. */
     9 assertEq(testLenientAndStrict('010',
    10                               parsesSuccessfully,
    11                               parseRaisesException(SyntaxError)),
    12          true);
    14 /* Octal integer literal in strict function body */
    15 assertEq(parseRaisesException(SyntaxError)
    16          ('function f() { "use strict"; 010; }'),
    17          true);
    20 /*
    21  * Octal integer literal after strict function body (restoration of
    22  * scanner state)
    23  */
    24 assertEq(parsesSuccessfully('function f() { "use strict"; }; 010'),
    25          true);
    27 /* Octal integer literal in function body */
    28 assertEq(parsesSuccessfully('function f() { 010; }'),
    29          true);
    31 reportCompare(true, true);

mercurial