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

10 lines
414 B
Plaintext
Raw Normal View History

tests/cases/compiler/numericIndexerConstraint.ts(2,5): error TS2412: Property '0' of type 'number' is not assignable to numeric index type 'RegExp'.
2014-07-13 01:04:16 +02:00
==== tests/cases/compiler/numericIndexerConstraint.ts (1 errors) ====
class C {
0: number;
~~~~~~~~~~
!!! error TS2412: Property '0' of type 'number' is not assignable to numeric index type 'RegExp'.
2014-07-13 01:04:16 +02:00
[x: number]: RegExp;
}