TypeScript/tests/baselines/reference/computedPropertyNames29_ES5.js
2015-02-23 17:44:48 -08:00

30 lines
589 B
TypeScript

//// [computedPropertyNames29_ES5.ts]
class C {
bar() {
() => {
var obj = {
[this.bar()]() { } // needs capture
};
}
return 0;
}
}
//// [computedPropertyNames29_ES5.js]
var C = (function () {
function C() {
}
C.prototype.bar = function () {
var _this = this;
(function () {
var obj = (_a = {},
_a[_this.bar()] = function () { },
_a
);
var _a;
});
return 0;
};
return C;
})();