mirror of
https://github.com/hanzoai/tsgo.git
synced 2026-10-30 19:37:15 +00:00
24 lines
754 B
Plaintext
24 lines
754 B
Plaintext
index.ts(3,14): error TS4023: Exported variable 'spread' has or is using name 'SYMBOL' from external module "bug" but cannot be named.
|
|
|
|
|
|
==== bug.ts (0 errors) ====
|
|
export const SYMBOL = Symbol()
|
|
|
|
export interface Interface {
|
|
readonly [SYMBOL]: string; // remove readonly and @showEmit to see the expected error
|
|
}
|
|
|
|
export function createInstance(): Interface {
|
|
return {
|
|
[SYMBOL]: ''
|
|
}
|
|
}
|
|
|
|
==== index.ts (1 errors) ====
|
|
import { createInstance } from './bug'
|
|
|
|
export const spread = {
|
|
~~~~~~
|
|
!!! error TS4023: Exported variable 'spread' has or is using name 'SYMBOL' from external module "bug" but cannot be named.
|
|
...createInstance(),
|
|
} |