wentout c59870c526
Mark class prototype as read-only (#12115)
* initial code 2 fix the issue #2025

* Mark class prototype as read-only

* Update fixtures

* Fix failure

* Update Babel 8 fixtures

* Disable in loose mode

* Update fixtures

Co-authored-by: Nicolò Ribaudo <nicolo.ribaudo@gmail.com>
2021-12-10 21:44:48 +01:00

35 lines
747 B
JavaScript

var A = /*#__PURE__*/function () {
"use strict";
function A() {
babelHelpers.classCallCheck(this, A);
}
babelHelpers.createClass(A, [{
key: "foo",
value: function foo() {
return "bar";
}
}]);
return A;
}();
var B = /*#__PURE__*/function (_A) {
"use strict";
babelHelpers.inherits(B, _A);
var _super = babelHelpers.createSuper(B);
function B(...args) {
var _thisSuper, _this;
babelHelpers.classCallCheck(this, B);
_this = _super.call(this, ...args);
_this.foo = babelHelpers.get((_thisSuper = babelHelpers.assertThisInitialized(_this), babelHelpers.getPrototypeOf(B.prototype)), "foo", _thisSuper).call(_thisSuper);
return _this;
}
return babelHelpers.createClass(B);
}(A);