TypeScript/tests/baselines/reference/accessorWithES5.js
Pathurs 5c85febb0c
Fix Get/Set being enumerable (#32264)
* Fix Get/Set being enumerable

fixes #3610

* fix tests

Co-authored-by: Nathan Shively-Sanders <293473+sandersn@users.noreply.github.com>
2020-02-27 14:08:20 -08:00

51 lines
786 B
TypeScript

//// [accessorWithES5.ts]
class C {
get x() {
return 1;
}
}
class D {
set x(v) {
}
}
var x = {
get a() { return 1 }
}
var y = {
set b(v) { }
}
//// [accessorWithES5.js]
var C = /** @class */ (function () {
function C() {
}
Object.defineProperty(C.prototype, "x", {
get: function () {
return 1;
},
enumerable: false,
configurable: true
});
return C;
}());
var D = /** @class */ (function () {
function D() {
}
Object.defineProperty(D.prototype, "x", {
set: function (v) {
},
enumerable: false,
configurable: true
});
return D;
}());
var x = {
get a() { return 1; }
};
var y = {
set b(v) { }
};