blob: 406a209707dab4763058f471022dd314228fb338 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
|
// Copyright (C) 2017 Valerie Young. All rights reserved.
// This code is governed by the BSD license found in the LICENSE file.
/*---
esid: sec-class-definitions-static-semantics-early-errors
path: language/statements/class/fields-computed-name-
name: no early error -- PropName of ComputedPropertyName not forbidden value
info: |
Static Semantics: PropName
...
ComputedPropertyName : [ AssignmentExpression ]
Return empty.
---*/
var x = "/*{ propname }*/";
class C {
/*{ static }*/ [x];
}
var c = new C();
assert.sameValue(c.hasOwnProperty("/*{ propname }*/"), true);
|