Debian Codegraph @

js/src/tests/test262/language/statements/function/enable-strict-via-outer-script-strict.js

raw
1 // |reftest| error:SyntaxError
2 'use strict';
3 // Copyright (c) 2012 Ecma International. All rights reserved.
4 // This code is governed by the BSD license found in the LICENSE file.
5
6 /*---
7 info: |
8 Refer 13;
9 The production FunctionBody : SourceElementsopt is evaluated as follows:
10 es5id: 13.0-9-s
11 description: >
12 Strict Mode - SourceElements is evaluated as strict mode code when
13 a FunctionDeclaration that is contained in strict mode code has an
14 inner function
15 negative:
16 phase: parse
17 type: SyntaxError
18 flags: [onlyStrict]
19 ---*/
20
21 $DONOTEVALUATE();
22
23 var _13_0_9_fun = function () {
24 function _13_0_9_inner() {
25 eval = 42;
26 }
27 };