swc/crates/swc_ecma_parser/tests/tsc/symbolProperty60.ts

23 lines
411 B
TypeScript
Raw Normal View History

// @target: es2015
// https://github.com/Microsoft/TypeScript/issues/20146
interface I1 {
[Symbol.toStringTag]: string;
[key: string]: number;
}
interface I2 {
[Symbol.toStringTag]: string;
[key: number]: boolean;
}
declare const mySymbol: unique symbol;
interface I3 {
[mySymbol]: string;
[key: string]: number;
}
interface I4 {
[mySymbol]: string;
[key: number]: boolean;
}