mirror of
https://github.com/swc-project/swc.git
synced 2024-12-20 04:01:39 +03:00
28 lines
379 B
TypeScript
28 lines
379 B
TypeScript
|
// @noImplicitOverride: true
|
||
|
// @useDefineForClassFields: true
|
||
|
// @target: es2015,esnext
|
||
|
|
||
|
class A {
|
||
|
public m1(): number {
|
||
|
return 0;
|
||
|
}
|
||
|
|
||
|
public m2(): number {
|
||
|
return 0;
|
||
|
}
|
||
|
|
||
|
public m3(): void {}
|
||
|
}
|
||
|
|
||
|
class B extends A {
|
||
|
override m1() {
|
||
|
return 10;
|
||
|
}
|
||
|
|
||
|
override m2(): number {
|
||
|
return 30;
|
||
|
}
|
||
|
|
||
|
override m3(): void {}
|
||
|
}
|