74 lines
No EOL
3.1 KiB
Text
74 lines
No EOL
3.1 KiB
Text
tests/cases/compiler/augmentedTypesEnum.ts(2,6): error TS2300: Duplicate identifier 'e1111'.
|
|
tests/cases/compiler/augmentedTypesEnum.ts(3,5): error TS2300: Duplicate identifier 'e1111'.
|
|
tests/cases/compiler/augmentedTypesEnum.ts(6,6): error TS2300: Duplicate identifier 'e2'.
|
|
tests/cases/compiler/augmentedTypesEnum.ts(7,10): error TS2300: Duplicate identifier 'e2'.
|
|
tests/cases/compiler/augmentedTypesEnum.ts(9,6): error TS2300: Duplicate identifier 'e3'.
|
|
tests/cases/compiler/augmentedTypesEnum.ts(10,5): error TS2300: Duplicate identifier 'e3'.
|
|
tests/cases/compiler/augmentedTypesEnum.ts(13,6): error TS2300: Duplicate identifier 'e4'.
|
|
tests/cases/compiler/augmentedTypesEnum.ts(14,7): error TS2300: Duplicate identifier 'e4'.
|
|
tests/cases/compiler/augmentedTypesEnum.ts(18,11): error TS2432: In an enum with multiple declarations, only one declaration can omit an initializer for its first enum element.
|
|
tests/cases/compiler/augmentedTypesEnum.ts(20,12): error TS2300: Duplicate identifier 'One'.
|
|
tests/cases/compiler/augmentedTypesEnum.ts(21,12): error TS2300: Duplicate identifier 'One'.
|
|
tests/cases/compiler/augmentedTypesEnum.ts(21,12): error TS2432: In an enum with multiple declarations, only one declaration can omit an initializer for its first enum element.
|
|
|
|
|
|
==== tests/cases/compiler/augmentedTypesEnum.ts (12 errors) ====
|
|
// enum then var
|
|
enum e1111 { One } // error
|
|
~~~~~
|
|
!!! error TS2300: Duplicate identifier 'e1111'.
|
|
var e1111 = 1; // error
|
|
~~~~~
|
|
!!! error TS2300: Duplicate identifier 'e1111'.
|
|
|
|
// enum then function
|
|
enum e2 { One } // error
|
|
~~
|
|
!!! error TS2300: Duplicate identifier 'e2'.
|
|
function e2() { } // error
|
|
~~
|
|
!!! error TS2300: Duplicate identifier 'e2'.
|
|
|
|
enum e3 { One } // error
|
|
~~
|
|
!!! error TS2300: Duplicate identifier 'e3'.
|
|
var e3 = () => { } // error
|
|
~~
|
|
!!! error TS2300: Duplicate identifier 'e3'.
|
|
|
|
// enum then class
|
|
enum e4 { One } // error
|
|
~~
|
|
!!! error TS2300: Duplicate identifier 'e4'.
|
|
class e4 { public foo() { } } // error
|
|
~~
|
|
!!! error TS2300: Duplicate identifier 'e4'.
|
|
|
|
// enum then enum
|
|
enum e5 { One }
|
|
enum e5 { Two } // error
|
|
~~~
|
|
!!! error TS2432: In an enum with multiple declarations, only one declaration can omit an initializer for its first enum element.
|
|
|
|
enum e5a { One } // error
|
|
~~~
|
|
!!! error TS2300: Duplicate identifier 'One'.
|
|
enum e5a { One } // error
|
|
~~~
|
|
!!! error TS2300: Duplicate identifier 'One'.
|
|
~~~
|
|
!!! error TS2432: In an enum with multiple declarations, only one declaration can omit an initializer for its first enum element.
|
|
|
|
// enum then internal module
|
|
enum e6 { One }
|
|
module e6 { } // ok
|
|
|
|
enum e6a { One }
|
|
module e6a { var y = 2; } // should be error
|
|
|
|
enum e6b { One }
|
|
module e6b { export var y = 2; } // should be error
|
|
|
|
// enum then import, messes with error reporting
|
|
//enum e7 { One }
|
|
//import e7 = require(''); // should be error |