Debian Codegraph @

js/src/tests/test262/language/expressions/prefix-decrement/arguments-nostrict.js

raw
1 // Copyright (c) 2018 Rick Waldron. All rights reserved.
2 // This code is governed by the BSD license found in the LICENSE file.
3
4 /*---
5 esid: sec-update-expressions
6 description: >
7 In non-strict code, "--arguments" does not produce an early error.
8 info: |
9 sec-identifiers-static-semantics-assignmenttargettype
10
11 1. If this IdentifierReference is contained in strict mode code and StringValue of Identifier is "eval" or "arguments", return strict.
12 2. Return simple.
13
14 sec-update-expressions-static-semantics-early-errors
15
16 UpdateExpression -- UnaryExpression
17
18 It is an early Reference Error if AssignmentTargetType of UnaryExpression is invalid.
19 It is an early Syntax Error if AssignmentTargetType of UnaryExpression is strict.
20 flags: [noStrict]
21 ---*/
22
23 if (false) {
24 --arguments;
25 }
26
27 reportCompare(0, 0);