TypeScript/tests/baselines/reference/importEquals1.errors.txt
Ron Buckton 66c3063b06
Add collision check for 'Reflect' when using super in static initializers (#44876)
* Add collision check for 'Reflect' when using super in static initializers

* PR feedback

* Accept baseline for new failing test
2021-07-10 12:48:54 -07:00

45 lines
1.7 KiB
Plaintext

/d.ts(2,5): error TS1361: 'types' cannot be used as a value because it was imported using 'import type'.
/e.ts(2,5): error TS1361: 'types' cannot be used as a value because it was imported using 'import type'.
/f.ts(2,5): error TS1361: 'types' cannot be used as a value because it was imported using 'import type'.
/g.ts(2,5): error TS1361: 'types' cannot be used as a value because it was imported using 'import type'.
==== /a.ts (0 errors) ====
export class A {}
==== /b.ts (0 errors) ====
import type * as types from './a';
export = types; // Error
==== /c.ts (0 errors) ====
import * as types from './a';
export = types;
==== /d.ts (1 errors) ====
import types from './b';
new types.A(); // Error
~~~~~
!!! error TS1361: 'types' cannot be used as a value because it was imported using 'import type'.
!!! related TS1376 /b.ts:1:18: 'types' was imported here.
==== /e.ts (1 errors) ====
import types = require('./b');
new types.A(); // Error
~~~~~
!!! error TS1361: 'types' cannot be used as a value because it was imported using 'import type'.
!!! related TS1376 /b.ts:1:18: 'types' was imported here.
==== /f.ts (1 errors) ====
import * as types from './b';
new types.A(); // Error
~~~~~
!!! error TS1361: 'types' cannot be used as a value because it was imported using 'import type'.
!!! related TS1376 /b.ts:1:18: 'types' was imported here.
==== /g.ts (1 errors) ====
import type types from './c'
new types.A(); // Error
~~~~~
!!! error TS1361: 'types' cannot be used as a value because it was imported using 'import type'.
!!! related TS1376 /g.ts:1:8: 'types' was imported here.