mirror of
https://github.com/swc-project/swc.git
synced 2024-12-11 07:35:15 +03:00
26 lines
511 B
TypeScript
26 lines
511 B
TypeScript
// @target: es5
|
|
// @useDefineForClassFields: true
|
|
// @noTypesAndSymbols: true
|
|
|
|
declare class B {
|
|
static a: any;
|
|
static f(): number;
|
|
a: number;
|
|
f(): number;
|
|
}
|
|
|
|
class C extends B {
|
|
static x: any = undefined!;
|
|
static y1 = this.x;
|
|
static y2 = this.x();
|
|
static y3 = this?.x();
|
|
static y4 = this[("x")]();
|
|
static y5 = this?.[("x")]();
|
|
static z3 = super.f();
|
|
static z4 = super["f"]();
|
|
|
|
// these should be unaffected
|
|
x = 1;
|
|
y = this.x;
|
|
z = super.f();
|
|
} |