TypeScript/tests/baselines/reference/noImplicitAnyMissingGetAccessor.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

47 lines
1.3 KiB
TypeScript

//// [noImplicitAnyMissingGetAccessor.ts]
abstract class Parent
{
public abstract set message(str);
}
class Child extends Parent {
_x: any;
public set message(str) {
this._x = str;
}
}
//// [noImplicitAnyMissingGetAccessor.js]
var __extends = (this && this.__extends) || (function () {
var extendStatics = function (d, b) {
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 extendStatics(d, b);
};
return function (d, b) {
extendStatics(d, b);
function __() { this.constructor = d; }
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
};
})();
var Parent = /** @class */ (function () {
function Parent() {
}
return Parent;
}());
var Child = /** @class */ (function (_super) {
__extends(Child, _super);
function Child() {
return _super !== null && _super.apply(this, arguments) || this;
}
Object.defineProperty(Child.prototype, "message", {
set: function (str) {
this._x = str;
},
enumerable: false,
configurable: true
});
return Child;
}(Parent));