swc/crates/swc_ecma_parser/tests/tsc/staticIndexSignature7.ts
2022-02-04 17:08:38 +09:00

10 lines
254 B
TypeScript

// @strict: true
class X {
static [index: string]: string;
static x = 12; // Should error, incompatible with index signature
}
class Y {
static [index: string]: string;
static foo() {} // should error, incompatible with index signature
}