keith_miller@apple.com | bcc77f2 | 2016-07-15 06:03:25 +0000 | [diff] [blame] | 1 | // Copyright (C) 2016 the V8 project authors. All rights reserved. |
| 2 | // This code is governed by the BSD license found in the LICENSE file. |
| 3 | /*--- |
| 4 | description: The body may not re-declare variables declared in the head |
| 5 | negative: SyntaxError |
| 6 | info: | |
| 7 | It is a Syntax Error if any element of the BoundNames of ForDeclaration |
| 8 | also occurs in the VarDeclaredNames of Statement. |
| 9 | esid: sec-for-in-and-for-of-statements-static-semantics-early-errors |
| 10 | es6id: 13.7.5 |
| 11 | ---*/ |
| 12 | |
| 13 | for (let x in {}) { |
| 14 | var x; |
| 15 | } |