static-init-await-binding.js (583B)
1 // Copyright (C) 2021 the V8 project authors. All rights reserved. 2 // This code is governed by the BSD license found in the LICENSE file. 3 /*--- 4 esid: sec-class-definitions-static-semantics-early-errors 5 description: The `await` keyword is interpreted as an Identifier within generator function expressions 6 info: | 7 ClassStaticBlockBody : ClassStaticBlockStatementList 8 9 [...] 10 - It is a Syntax Error if ContainsAwait of ClassStaticBlockStatementList is true. 11 features: [class-static-block] 12 ---*/ 13 14 class C { 15 static { 16 (function * await (await) {}); 17 } 18 } 19 20 reportCompare(0, 0);