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

16 lines
493 B
Plaintext
Raw Normal View History

tests/cases/compiler/classIndexer3.ts(9,5): error TS2411: Property 'y' of type 'string' is not assignable to string index type 'number'.
2014-07-13 01:04:16 +02:00
==== tests/cases/compiler/classIndexer3.ts (1 errors) ====
class C123 {
[s: string]: number;
constructor() {
}
}
class D123 extends C123 {
x: number;
y: string;
~~~~~~~~~~
!!! error TS2411: Property 'y' of type 'string' is not assignable to string index type 'number'.
2014-07-13 01:04:16 +02:00
}