Closed
Description
TypeScript Version: 1.8.7
Code
class A {
a = true;
constructor() {
}
}
class B extends A {
b = true;
constructor() {
super();
}
}
new B();
Expected behavior:
The b field should be set to true, then super() called.
Actual behavior:
The super constructor is called first, then b field is initialized.
Generated JS
var B = (function (_super) {
__extends(B, _super);
function B() {
_super.call(this);
this.b = true;
}
return B;
}(A));