mirror of
https://github.com/microsoft/TypeScript.git
synced 2026-05-29 16:29:19 -05:00
Fix missing error for accessing type-only export * member through namespace (#57176)
This commit is contained in:
@@ -0,0 +1,9 @@
|
||||
// @filename: main.ts
|
||||
import * as intermediate from './intermediate'
|
||||
const ghost: intermediate.Ghost = new intermediate.Ghost()
|
||||
|
||||
// @filename: intermediate.ts
|
||||
export type * from './ghost'
|
||||
|
||||
// @filename: ghost.ts
|
||||
export class Ghost {}
|
||||
@@ -0,0 +1,11 @@
|
||||
// @filename: main.ts
|
||||
import { c } from './types'
|
||||
import * as types from './types'
|
||||
console.log(c) // Fails as expected, import is still allowed though.
|
||||
console.log(types.c) // Expected an error here.
|
||||
|
||||
// @filename: types.ts
|
||||
export type * from './values'
|
||||
|
||||
// @filename: values.ts
|
||||
export const c = 10
|
||||
Reference in New Issue
Block a user