Debian Codegraph @

js/src/tests/test262/language/statements/class/class-name-ident-yield.js

raw
1 // |reftest| error:SyntaxError
2 // Copyright (C) 2018 André Bargull. All rights reserved.
3 // This code is governed by the BSD license found in the LICENSE file.
4
5 /*---
6 esid: sec-class-definitions
7 description: >
8 `yield` is not a valid class-name identifier.
9 info: |
10 12.1.1 Static Semantics: Early Errors
11
12 IdentifierReference : yield
13
14 It is a Syntax Error if the code matched by this production is contained in strict mode code.
15
16 10.2.1 Strict Mode Code
17
18 All parts of a ClassDeclaration or a ClassExpression are strict mode code.
19 negative:
20 phase: parse
21 type: SyntaxError
22 ---*/
23
24 $DONOTEVALUATE();
25
26 class yield {}