30 lines
1.8 KiB
Plaintext
30 lines
1.8 KiB
Plaintext
tests/cases/conformance/es6/computedProperties/computedPropertyNames5.ts(3,5): error TS2464: A computed property name must be of type 'string', 'number', or 'any'.
|
|
tests/cases/conformance/es6/computedProperties/computedPropertyNames5.ts(4,5): error TS2464: A computed property name must be of type 'string', 'number', or 'any'.
|
|
tests/cases/conformance/es6/computedProperties/computedPropertyNames5.ts(5,5): error TS2464: A computed property name must be of type 'string', 'number', or 'any'.
|
|
tests/cases/conformance/es6/computedProperties/computedPropertyNames5.ts(6,5): error TS2464: A computed property name must be of type 'string', 'number', or 'any'.
|
|
tests/cases/conformance/es6/computedProperties/computedPropertyNames5.ts(7,5): error TS2464: A computed property name must be of type 'string', 'number', or 'any'.
|
|
tests/cases/conformance/es6/computedProperties/computedPropertyNames5.ts(8,5): error TS2464: A computed property name must be of type 'string', 'number', or 'any'.
|
|
|
|
|
|
==== tests/cases/conformance/es6/computedProperties/computedPropertyNames5.ts (6 errors) ====
|
|
var b: boolean;
|
|
var v = {
|
|
[b]: 0,
|
|
~~~
|
|
!!! error TS2464: A computed property name must be of type 'string', 'number', or 'any'.
|
|
[true]: 1,
|
|
~~~~~~
|
|
!!! error TS2464: A computed property name must be of type 'string', 'number', or 'any'.
|
|
[[]]: 0,
|
|
~~~~
|
|
!!! error TS2464: A computed property name must be of type 'string', 'number', or 'any'.
|
|
[{}]: 0,
|
|
~~~~
|
|
!!! error TS2464: A computed property name must be of type 'string', 'number', or 'any'.
|
|
[undefined]: undefined,
|
|
~~~~~~~~~~~
|
|
!!! error TS2464: A computed property name must be of type 'string', 'number', or 'any'.
|
|
[null]: null
|
|
~~~~~~
|
|
!!! error TS2464: A computed property name must be of type 'string', 'number', or 'any'.
|
|
} |