We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
TypeScript Version: 2.4.0-dev.20170609
Code
function decorate(target) { } class A { } @decorate class B extends A { private static readonly STATIC = 'value'; foo() { return B.STATIC; } }
Actual behavior: (compiled js) look below: __extends(B, _super); is called with hoisted B = undefined.
var __extends = (this && this.__extends) || (function () { var extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; return function (d, b) { extendStatics(d, b); function __() { this.constructor = d; } d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); }; })(); var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) { var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d; if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc); else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r; return c > 3 && r && Object.defineProperty(target, key, r), r; }; function decorate(target) { } var A = (function () { function A() { } return A; }()); var B = (function (_super) { __extends(B, _super); var B = B_1 = function B() { return _super !== null && _super.apply(this, arguments) || this; }; B.prototype.foo = function () { return B_1.STATIC; }; B.STATIC = 'value'; B = B_1 = __decorate([ decorate ], B); return B; var B_1; }(A));
The text was updated successfully, but these errors were encountered:
Having the same issue. Had to downgrade tsc version. Seems it got introduced with 2.4.0-dev.20170601
2.4.0-dev.20170601
Sorry, something went wrong.
Maybe there should be a "run emitted JS" category of tests. Neverthless thanks for the quick fix 🌹 ❤️
rbuckton
No branches or pull requests
TypeScript Version: 2.4.0-dev.20170609
Code
Actual behavior: (compiled js)
look below: __extends(B, _super); is called with hoisted B = undefined.
The text was updated successfully, but these errors were encountered: