mirror of
https://github.com/swc-project/swc.git
synced 2024-11-28 11:13:43 +03:00
18 lines
320 B
TypeScript
18 lines
320 B
TypeScript
// @noEmit: true
|
|
// @allowJs: true
|
|
// @checkJs: true
|
|
// @noImplicitAny: true
|
|
// @strictNullChecks: true
|
|
// @Filename: a.js
|
|
class Base {
|
|
m() {
|
|
this.p = 1
|
|
}
|
|
}
|
|
class Derived extends Base {
|
|
m() {
|
|
// should be OK, and p should have type number | undefined from its base
|
|
this.p = 1
|
|
}
|
|
}
|