Debian Codegraph @

js/src/tests/test262/language/statements/for-in/head-const-bound-names-fordecl-tdz.js

raw
1 // Copyright (C) 2014 the V8 project authors. All rights reserved.
2 // This code is governed by the BSD license found in the LICENSE file.
3 /*---
4 es6id: 13.6.4.12_S2
5 description: >
6 ForIn/Of: Bound names of ForDeclaration are in TDZ (for-of)
7 ---*/
8
9 assert.throws(ReferenceError, function() {
10 let x = 1;
11 for (const x in { x }) {}
12 });
13
14 reportCompare(0, 0);