TypeScript/tests/baselines/reference/parserComputedPropertyName34.errors.txt

17 lines
919 B
Plaintext
Raw Normal View History

2014-11-18 23:34:04 +01:00
tests/cases/conformance/parser/ecmascript6/ComputedPropertyNames/parserComputedPropertyName34.ts(3,5): error TS1164: Computed property names are not allowed in enums.
tests/cases/conformance/parser/ecmascript6/ComputedPropertyNames/parserComputedPropertyName34.ts(3,11): error TS2304: Cannot find name 'id'.
tests/cases/conformance/parser/ecmascript6/ComputedPropertyNames/parserComputedPropertyName34.ts(4,5): error TS1164: Computed property names are not allowed in enums.
==== tests/cases/conformance/parser/ecmascript6/ComputedPropertyNames/parserComputedPropertyName34.ts (3 errors) ====
enum E {
// no ASI, comma expected
[e] = id++,
~~~
2014-11-18 23:34:04 +01:00
!!! error TS1164: Computed property names are not allowed in enums.
~~
!!! error TS2304: Cannot find name 'id'.
[e2] = 1
~~~~
2014-11-18 23:34:04 +01:00
!!! error TS1164: Computed property names are not allowed in enums.
}