13 lines
481 B
Text
13 lines
481 B
Text
|
==== tests/cases/compiler/typeOfEnumAndVarRedeclarations.ts (1 errors) ====
|
||
|
enum E {
|
||
|
a
|
||
|
}
|
||
|
enum E {
|
||
|
b = 1
|
||
|
}
|
||
|
var x = E;
|
||
|
var x: { a: E; b: E;[x: number]: string; }; // Shouldnt error
|
||
|
var y = E;
|
||
|
var y: { a: E; b: E;[x: number]: string;[x: number]: string } // two errors: the types are not identical and duplicate signatures
|
||
|
~~~~~~~~~~~~~~~~~~~
|
||
|
!!! Duplicate number index signature.
|