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

52 lines
3.5 KiB
Plaintext

tests/cases/conformance/es6/computedProperties/computedPropertyNames12.ts(5,5): error TS1166: Computed property names are not allowed in class property declarations.
tests/cases/conformance/es6/computedProperties/computedPropertyNames12.ts(6,5): error TS1166: Computed property names are not allowed in class property declarations.
tests/cases/conformance/es6/computedProperties/computedPropertyNames12.ts(7,12): error TS1166: Computed property names are not allowed in class property declarations.
tests/cases/conformance/es6/computedProperties/computedPropertyNames12.ts(8,5): error TS1166: Computed property names are not allowed in class property declarations.
tests/cases/conformance/es6/computedProperties/computedPropertyNames12.ts(9,5): error TS1166: Computed property names are not allowed in class property declarations.
tests/cases/conformance/es6/computedProperties/computedPropertyNames12.ts(10,12): error TS1166: Computed property names are not allowed in class property declarations.
tests/cases/conformance/es6/computedProperties/computedPropertyNames12.ts(11,5): error TS1166: Computed property names are not allowed in class property declarations.
tests/cases/conformance/es6/computedProperties/computedPropertyNames12.ts(12,5): error TS1166: Computed property names are not allowed in class property declarations.
tests/cases/conformance/es6/computedProperties/computedPropertyNames12.ts(13,12): error TS1166: Computed property names are not allowed in class property declarations.
tests/cases/conformance/es6/computedProperties/computedPropertyNames12.ts(14,5): error TS1166: Computed property names are not allowed in class property declarations.
tests/cases/conformance/es6/computedProperties/computedPropertyNames12.ts(15,12): error TS1166: Computed property names are not allowed in class property declarations.
==== tests/cases/conformance/es6/computedProperties/computedPropertyNames12.ts (11 errors) ====
var s: string;
var n: number;
var a: any;
class C {
[s]: number;
~~~
!!! error TS1166: Computed property names are not allowed in class property declarations.
[n] = n;
~~~
!!! error TS1166: Computed property names are not allowed in class property declarations.
static [s + s]: string;
~~~~~~~
!!! error TS1166: Computed property names are not allowed in class property declarations.
[s + n] = 2;
~~~~~~~
!!! error TS1166: Computed property names are not allowed in class property declarations.
[+s]: typeof s;
~~~~
!!! error TS1166: Computed property names are not allowed in class property declarations.
static [""]: number;
~~~~
!!! error TS1166: Computed property names are not allowed in class property declarations.
[0]: number;
~~~
!!! error TS1166: Computed property names are not allowed in class property declarations.
[a]: number;
~~~
!!! error TS1166: Computed property names are not allowed in class property declarations.
static [<any>true]: number;
~~~~~~~~~~~
!!! error TS1166: Computed property names are not allowed in class property declarations.
[`hello bye`] = 0;
~~~~~~~~~~~~~
!!! error TS1166: Computed property names are not allowed in class property declarations.
static [`hello ${a} bye`] = 0
~~~~~~~~~~~~~~~~~~
!!! error TS1166: Computed property names are not allowed in class property declarations.
}