Add "use strict" directive (#7411)

* #7349
- Add "use strict" directive to transformed class bodies

* Update tests (#7349)

* Add test for program with use strict directive (#7349)

* Update tests (#7349)

* Update source mapping (#7349)

* Add test for parent blockStatement with use strict directive (#7349)

* Update tests (#7349)

* Update tests (#7349)

* Update tests (#7349)

* Add test for constructor-only class (#7349)

* Constructor only classes are strict, too

But constructor only that use non-simple parameters must use a strict function wrapper.

* Fix test

* Wrapper not needed if class is already strict

* Revert change to lerna.json
This commit is contained in:
Markus Török 2018-04-10 23:33:38 +02:00 committed by Justin Ridgewell
parent fdd0789936
commit 6597a472b3
127 changed files with 410 additions and 23 deletions

View File

@ -1,6 +1,8 @@
var Foo =
/*#__PURE__*/
function (_Bar) {
"use strict";
babelHelpers.inherits(Foo, _Bar);
function Foo(options) {

View File

@ -1,6 +1,8 @@
var Test =
/*#__PURE__*/
function () {
"use strict";
function Test() {
babelHelpers.classCallCheck(this, Test);
}

View File

@ -4,7 +4,7 @@
"column": 10
},
"generated": {
"line": 11,
"line": 13,
"column": 15
}
}]

View File

@ -24,6 +24,8 @@ var _ref4 = `template${expression}`;
var MyClass =
/*#__PURE__*/
function () {
"use strict";
function MyClass() {
babelHelpers.classCallCheck(this, MyClass);
this[null] = "null";

View File

@ -1,6 +1,8 @@
var foo = "bar";
var Foo = function Foo() {
"use strict";
babelHelpers.classCallCheck(this, Foo);
this.bar = foo;
var _foo = "foo";

View File

@ -1,6 +1,8 @@
var Foo =
/*#__PURE__*/
function (_Bar) {
"use strict";
babelHelpers.inherits(Foo, _Bar);
function Foo(...args) {

View File

@ -1,6 +1,8 @@
var Child =
/*#__PURE__*/
function (_Parent) {
"use strict";
babelHelpers.inherits(Child, _Parent);
function Child() {

View File

@ -2,6 +2,8 @@ function test(x) {
var _x = x;
var F = function F() {
"use strict";
babelHelpers.classCallCheck(this, F);
this[_x] = 1;
};

View File

@ -1,4 +1,6 @@
var Foo = function Foo() {
"use strict";
babelHelpers.classCallCheck(this, Foo);
this.bar = void 0;
};

View File

@ -1,4 +1,6 @@
var Foo = function Foo() {
"use strict";
babelHelpers.classCallCheck(this, Foo);
this.bar = "foo";
};

View File

@ -4,6 +4,8 @@ function withContext(ComposedComponent) {
return _temp = _class =
/*#__PURE__*/
function (_Component) {
"use strict";
babelHelpers.inherits(WithContext, _Component);
function WithContext() {

View File

@ -1,5 +1,7 @@
var _class, _temp;
var Foo = (_temp = _class = function Foo() {
"use strict";
babelHelpers.classCallCheck(this, Foo);
}, _class.num = 0, _temp);

View File

@ -1,4 +1,6 @@
var Foo = function Foo() {
"use strict";
babelHelpers.classCallCheck(this, Foo);
};

View File

@ -1,4 +1,6 @@
var Foo = function Foo() {
"use strict";
babelHelpers.classCallCheck(this, Foo);
};

View File

@ -1,6 +1,8 @@
var A =
/*#__PURE__*/
function () {
"use strict";
function A() {
babelHelpers.classCallCheck(this, A);
}
@ -17,6 +19,8 @@ function () {
var B =
/*#__PURE__*/
function (_A) {
"use strict";
babelHelpers.inherits(B, _A);
function B(...args) {

View File

@ -1,6 +1,8 @@
var Foo =
/*#__PURE__*/
function (_Bar) {
"use strict";
babelHelpers.inherits(Foo, _Bar);
function Foo() {

View File

@ -1,6 +1,8 @@
var Foo =
/*#__PURE__*/
function (_Bar) {
"use strict";
babelHelpers.inherits(Foo, _Bar);
function Foo() {

View File

@ -1,4 +1,6 @@
var A = function A(_force) {
"use strict";
babelHelpers.classCallCheck(this, A);
this.force = force;
this.foo = babelHelpers.get(babelHelpers.getPrototypeOf(A.prototype), "method", babelHelpers.assertThisInitialized(this)).call(this);

View File

@ -24,6 +24,8 @@ var _ref4 = `template${expression}`;
var MyClass =
/*#__PURE__*/
function () {
"use strict";
function MyClass() {
babelHelpers.classCallCheck(this, MyClass);
Object.defineProperty(this, null, {

View File

@ -1,6 +1,8 @@
var foo = "bar";
var Foo = function Foo() {
"use strict";
babelHelpers.classCallCheck(this, Foo);
Object.defineProperty(this, "bar", {
configurable: true,

View File

@ -1,6 +1,8 @@
var Foo =
/*#__PURE__*/
function (_Bar) {
"use strict";
babelHelpers.inherits(Foo, _Bar);
function Foo(...args) {

View File

@ -1,6 +1,8 @@
var Child =
/*#__PURE__*/
function (_Parent) {
"use strict";
babelHelpers.inherits(Child, _Parent);
function Child() {

View File

@ -2,6 +2,8 @@ function test(x) {
var _x = x;
var F = function F() {
"use strict";
babelHelpers.classCallCheck(this, F);
Object.defineProperty(this, _x, {
configurable: true,

View File

@ -1,4 +1,6 @@
var Foo = function Foo() {
"use strict";
babelHelpers.classCallCheck(this, Foo);
Object.defineProperty(this, "bar", {
configurable: true,

View File

@ -1,4 +1,6 @@
var Foo = function Foo() {
"use strict";
babelHelpers.classCallCheck(this, Foo);
Object.defineProperty(this, "bar", {
configurable: true,

View File

@ -4,6 +4,8 @@ function withContext(ComposedComponent) {
return _temp = _class =
/*#__PURE__*/
function (_Component) {
"use strict";
babelHelpers.inherits(WithContext, _Component);
function WithContext() {

View File

@ -1,6 +1,8 @@
var _class, _temp;
var Foo = (_temp = _class = function Foo() {
"use strict";
babelHelpers.classCallCheck(this, Foo);
}, Object.defineProperty(_class, "num", {
configurable: true,

View File

@ -1,4 +1,6 @@
var Foo = function Foo() {
"use strict";
babelHelpers.classCallCheck(this, Foo);
};

View File

@ -1,4 +1,6 @@
var Foo = function Foo() {
"use strict";
babelHelpers.classCallCheck(this, Foo);
};

View File

@ -1,6 +1,8 @@
var A =
/*#__PURE__*/
function () {
"use strict";
function A() {
babelHelpers.classCallCheck(this, A);
}
@ -17,6 +19,8 @@ function () {
var B =
/*#__PURE__*/
function (_A) {
"use strict";
babelHelpers.inherits(B, _A);
function B(...args) {

View File

@ -1,6 +1,8 @@
var Foo =
/*#__PURE__*/
function (_Bar) {
"use strict";
babelHelpers.inherits(Foo, _Bar);
function Foo() {

View File

@ -1,6 +1,8 @@
var Foo =
/*#__PURE__*/
function (_Bar) {
"use strict";
babelHelpers.inherits(Foo, _Bar);
function Foo() {

View File

@ -1,4 +1,6 @@
var A = function A(_force) {
"use strict";
babelHelpers.classCallCheck(this, A);
Object.defineProperty(this, "force", {
configurable: true,

View File

@ -17,6 +17,8 @@ function _getPrototypeOf(o) { _getPrototypeOf = Object.getPrototypeOf || functio
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
var Test = function Test() {
"use strict";
var _this2 = this;
_classCallCheck(this, Test);

View File

@ -4,6 +4,8 @@ function withContext(ComposedComponent) {
return _temp = _class =
/*#__PURE__*/
function (_Component) {
"use strict";
babelHelpers.inherits(WithContext, _Component);
function WithContext() {

View File

@ -30,6 +30,8 @@ function generateAsyncAction(type) {
var A =
/*#__PURE__*/
function (_B) {
"use strict";
_inherits(A, _B);
function A(timestamp) {

View File

@ -11,6 +11,8 @@ function _two() {}
let Test1 =
/*#__PURE__*/
function () {
"use strict";
function Test1() {
_classCallCheck(this, Test1);
}

View File

@ -688,16 +688,51 @@ export default function transformClass(
classState.staticPropBody.map(fn => fn(t.cloneNode(classState.classRef))),
);
if (classState.classId && body.length === 1) {
const strictParent = path.findParent(path => {
if (path.isProgram() && path.node.sourceType === "module") {
return true;
}
if (path.isClassBody()) {
return true;
}
if (!path.isProgram() && !path.isBlockStatement()) {
return false;
}
return path.node.directives.some(
directive => directive.value.value === "use strict",
);
});
let constructorOnly = classState.classId && body.length === 1;
if (constructorOnly && !strictParent) {
for (const param of classState.construct.params) {
// It's illegal to put a use strict directive into the body of a function
// with non-simple parameters for some reason. So, we have to use a strict
// wrapper function.
if (!t.isIdentifier(param)) {
constructorOnly = false;
break;
}
}
}
const directives = constructorOnly ? body[0].body.directives : [];
if (!strictParent) {
directives.push(t.directive(t.directiveLiteral("use strict")));
}
if (constructorOnly) {
// named class with only a constructor
return t.toExpression(body[0]);
}
body.push(t.returnStatement(t.cloneNode(classState.classRef)));
const container = t.arrowFunctionExpression(
closureParams,
t.blockStatement(body),
t.blockStatement(body, directives),
);
return t.callExpression(container, closureArgs);
}

View File

@ -11,6 +11,8 @@ function _getPrototypeOf(o) { _getPrototypeOf = Object.getPrototypeOf || functio
var List =
/*#__PURE__*/
function (_Array) {
"use strict";
_inheritsLoose(List, _Array);
function List() {

View File

@ -1,10 +1,14 @@
let Array = function Array() {
"use strict";
babelHelpers.classCallCheck(this, Array);
};
let List =
/*#__PURE__*/
function (_Array) {
"use strict";
babelHelpers.inherits(List, _Array);
function List() {

View File

@ -17,6 +17,8 @@ function _getPrototypeOf(o) { _getPrototypeOf = Object.getPrototypeOf || functio
var List =
/*#__PURE__*/
function (_Array) {
"use strict";
_inherits(List, _Array);
function List() {

View File

@ -1 +1,3 @@
let A = function A() {};
let A = function A() {
"use strict";
};

View File

@ -1,10 +1,14 @@
let A = function A() {
"use strict";
console.log('a');
};
let B =
/*#__PURE__*/
function () {
"use strict";
function B() {}
var _proto = B.prototype;

View File

@ -2,11 +2,15 @@ function _assertThisInitialized(self) { if (self === void 0) { throw new Referen
function _inheritsLoose(subClass, superClass) { subClass.prototype = Object.create(superClass.prototype); subClass.prototype.constructor = subClass; subClass.__proto__ = superClass; }
let B = function B() {};
let B = function B() {
"use strict";
};
let A =
/*#__PURE__*/
function (_B) {
"use strict";
_inheritsLoose(A, _B);
function A(track) {

View File

@ -1,6 +1,8 @@
var Test =
/*#__PURE__*/
function (_Foo) {
"use strict";
babelHelpers.inheritsLoose(Test, _Foo);
function Test() {

View File

@ -1,6 +1,8 @@
var Test =
/*#__PURE__*/
function (_Foo) {
"use strict";
babelHelpers.inheritsLoose(Test, _Foo);
function Test() {

View File

@ -0,0 +1,6 @@
function t() {
"use strict";
class Foo {
method() {}
}
}

View File

@ -0,0 +1,15 @@
function t() {
"use strict";
var Foo =
/*#__PURE__*/
function () {
function Foo() {}
var _proto = Foo.prototype;
_proto.method = function method() {};
return Foo;
}();
}

View File

@ -1,6 +1,8 @@
var Test =
/*#__PURE__*/
function (_Foo) {
"use strict";
babelHelpers.inheritsLoose(Test, _Foo);
function Test() {

View File

@ -1,6 +1,8 @@
var x =
/*#__PURE__*/
function () {
"use strict";
var _proto = x.prototype;
_proto.f = function f() {

View File

@ -1,6 +1,8 @@
var Foo =
/*#__PURE__*/
function (_Bar) {
"use strict";
babelHelpers.inheritsLoose(Foo, _Bar);
function Foo() {

View File

@ -1,6 +1,8 @@
var Child =
/*#__PURE__*/
function (_Base) {
"use strict";
babelHelpers.inheritsLoose(Child, _Base);
function Child() {

View File

@ -1,6 +1,8 @@
var Child =
/*#__PURE__*/
function (_Base) {
"use strict";
babelHelpers.inheritsLoose(Child, _Base);
function Child() {

View File

@ -1,6 +1,8 @@
var Foo =
/*#__PURE__*/
function () {
"use strict";
function Foo() {}
var _proto = Foo.prototype;

View File

@ -2,6 +2,8 @@
var C =
/*#__PURE__*/
function () {
"use strict";
function C() {}
var _proto = C.prototype;

View File

@ -1,6 +1,8 @@
var Test =
/*#__PURE__*/
function () {
"use strict";
function Test() {}
var _proto = Test.prototype;

View File

@ -0,0 +1,7 @@
"use strict";
class Foo {
method() {
}
}

View File

@ -0,0 +1,13 @@
"use strict";
var Foo =
/*#__PURE__*/
function () {
function Foo() {}
var _proto = Foo.prototype;
_proto.method = function method() {};
return Foo;
}();

View File

@ -1,6 +1,8 @@
var BaseController =
/*#__PURE__*/
function (_Chaplin$Controller) {
"use strict";
babelHelpers.inheritsLoose(BaseController, _Chaplin$Controller);
function BaseController() {
@ -13,6 +15,8 @@ function (_Chaplin$Controller) {
var BaseController2 =
/*#__PURE__*/
function (_Chaplin$Controller$A) {
"use strict";
babelHelpers.inheritsLoose(BaseController2, _Chaplin$Controller$A);
function BaseController2() {

View File

@ -1,6 +1,8 @@
var Test =
/*#__PURE__*/
function (_Foo) {
"use strict";
babelHelpers.inheritsLoose(Test, _Foo);
function Test() {

View File

@ -1,3 +1,5 @@
var Test = function Test() {
"use strict";
Function.prototype.hasOwnProperty.call(this, "test");
};

View File

@ -1,6 +1,8 @@
var A =
/*#__PURE__*/
function (_B) {
"use strict";
babelHelpers.inherits(A, _B);
function A() {

View File

@ -2,6 +2,8 @@ var x = {
Foo:
/*#__PURE__*/
function (_Foo) {
"use strict";
babelHelpers.inherits(_class, _Foo);
function _class() {

View File

@ -1,10 +1,14 @@
var A = function A() {
"use strict";
babelHelpers.classCallCheck(this, A);
};
var B =
/*#__PURE__*/
function (_A) {
"use strict";
babelHelpers.inherits(B, _A);
function B() {

View File

@ -1,6 +1,8 @@
var A =
/*#__PURE__*/
function () {
"use strict";
function A() {
babelHelpers.classCallCheck(this, A);
}

View File

@ -1,6 +1,8 @@
var Example =
/*#__PURE__*/
function () {
"use strict";
function Example() {}
var _proto = Example.prototype;

View File

@ -1,6 +1,8 @@
var Foo =
/*#__PURE__*/
function () {
"use strict";
function Foo(val) {
babelHelpers.classCallCheck(this, Foo);
this._val = val;

View File

@ -15,12 +15,16 @@ function _instanceof(left, right) { if (right != null && typeof Symbol !== "unde
function _classCallCheck(instance, Constructor) { if (!_instanceof(instance, Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
var B = function B() {
"use strict";
_classCallCheck(this, B);
};
var A =
/*#__PURE__*/
function (_B) {
"use strict";
_inherits(A, _B);
function A(track) {

View File

@ -1,6 +1,8 @@
var Test =
/*#__PURE__*/
function (_Foo) {
"use strict";
babelHelpers.inherits(Test, _Foo);
function Test() {

View File

@ -1,6 +1,8 @@
var Test =
/*#__PURE__*/
function (_Foo) {
"use strict";
babelHelpers.inherits(Test, _Foo);
function Test() {

View File

@ -1,6 +1,8 @@
var Test =
/*#__PURE__*/
function (_Foo) {
"use strict";
babelHelpers.inherits(Test, _Foo);
function Test() {

View File

@ -1,6 +1,8 @@
var Foo =
/*#__PURE__*/
function () {
"use strict";
function Foo() {
babelHelpers.classCallCheck(this, Foo);
}

View File

@ -1,4 +1,6 @@
var Example = function Example() {
"use strict";
babelHelpers.classCallCheck(this, Example);
var _Example;

View File

@ -0,0 +1,5 @@
class Foo {
constructor() {
}
}

View File

@ -0,0 +1,5 @@
var Foo = function Foo() {
"use strict";
babelHelpers.classCallCheck(this, Foo);
};

View File

@ -1,4 +1,6 @@
var Test = function Test() {
"use strict";
babelHelpers.classCallCheck(this, Test);
this.state = "test";
};
@ -6,6 +8,8 @@ var Test = function Test() {
var Foo =
/*#__PURE__*/
function (_Bar) {
"use strict";
babelHelpers.inherits(Foo, _Bar);
function Foo() {
@ -21,6 +25,8 @@ function (_Bar) {
}(Bar);
var ConstructorScoping = function ConstructorScoping() {
"use strict";
babelHelpers.classCallCheck(this, ConstructorScoping);
var bar;
{

View File

@ -1,6 +1,8 @@
var Foo =
/*#__PURE__*/
function (_Bar) {
"use strict";
babelHelpers.inherits(Foo, _Bar);
function Foo() {

View File

@ -1,6 +1,8 @@
var Foo =
/*#__PURE__*/
function (_Bar) {
"use strict";
babelHelpers.inherits(Foo, _Bar);
function Foo() {

View File

@ -1,6 +1,8 @@
var Foo =
/*#__PURE__*/
function (_Bar) {
"use strict";
babelHelpers.inherits(Foo, _Bar);
function Foo() {

View File

@ -1,6 +1,8 @@
var Foo =
/*#__PURE__*/
function (_Bar) {
"use strict";
babelHelpers.inherits(Foo, _Bar);
function Foo() {

View File

@ -1,6 +1,8 @@
var Foo =
/*#__PURE__*/
function (_Bar) {
"use strict";
babelHelpers.inherits(Foo, _Bar);
function Foo() {

View File

@ -1,6 +1,8 @@
var Child =
/*#__PURE__*/
function (_Base) {
"use strict";
babelHelpers.inherits(Child, _Base);
function Child() {

View File

@ -1,6 +1,8 @@
var Child =
/*#__PURE__*/
function (_Base) {
"use strict";
babelHelpers.inherits(Child, _Base);
function Child() {

View File

@ -1,5 +1,7 @@
var o = {
foo: function foo() {
"use strict";
babelHelpers.classCallCheck(this, foo);
}
};

View File

@ -1,6 +1,8 @@
var Test =
/*#__PURE__*/
function () {
"use strict";
function Test() {
babelHelpers.classCallCheck(this, Test);
}

View File

@ -1,6 +1,8 @@
var Test =
/*#__PURE__*/
function () {
"use strict";
function Test() {
babelHelpers.classCallCheck(this, Test);
}

View File

@ -1,6 +1,8 @@
var Test =
/*#__PURE__*/
function () {
"use strict";
function Test() {
babelHelpers.classCallCheck(this, Test);
}

View File

@ -1,6 +1,8 @@
var Test =
/*#__PURE__*/
function () {
"use strict";
function Test() {
babelHelpers.classCallCheck(this, Test);
}

View File

@ -2,6 +2,8 @@
var C =
/*#__PURE__*/
function () {
"use strict";
function C() {
babelHelpers.classCallCheck(this, C);
}

View File

@ -1,3 +1,5 @@
var Test = function Test() {
"use strict";
babelHelpers.classCallCheck(this, Test);
};

View File

@ -1,5 +1,6 @@
var MyCtrl = function MyCtrl(a) {
"any directive prologue";
"use strict";
babelHelpers.classCallCheck(this, MyCtrl);
foo;
@ -8,6 +9,7 @@ var MyCtrl = function MyCtrl(a) {
var MyCtrl2 = function MyCtrl2(a) {
"a";
"b";
"use strict";
babelHelpers.classCallCheck(this, MyCtrl2);
foo;
@ -15,6 +17,7 @@ var MyCtrl2 = function MyCtrl2(a) {
var MyCtrl3 = function MyCtrl3(a) {
"a";
"use strict";
babelHelpers.classCallCheck(this, MyCtrl3);
foo;

View File

@ -2,6 +2,8 @@
var Foo =
/*#__PURE__*/
function () {
"use strict";
function Foo() {
babelHelpers.classCallCheck(this, Foo);
}

View File

@ -1,9 +1,13 @@
var BaseView = function BaseView() {
"use strict";
babelHelpers.classCallCheck(this, BaseView);
this.autoRender = true;
};
var BaseView = function BaseView() {
"use strict";
babelHelpers.classCallCheck(this, BaseView);
this.autoRender = true;
};
@ -11,6 +15,8 @@ var BaseView = function BaseView() {
var BaseView =
/*#__PURE__*/
function () {
"use strict";
function BaseView() {
babelHelpers.classCallCheck(this, BaseView);
}

View File

@ -1,6 +1,8 @@
var A =
/*#__PURE__*/
function () {
"use strict";
function A() {
babelHelpers.classCallCheck(this, A);
}

View File

@ -1,6 +1,8 @@
var TestEmpty =
/*#__PURE__*/
function (_ref) {
"use strict";
babelHelpers.inherits(TestEmpty, _ref);
function TestEmpty() {
@ -12,6 +14,8 @@ function (_ref) {
}(
/*#__PURE__*/
function () {
"use strict";
function _class() {
babelHelpers.classCallCheck(this, _class);
}
@ -22,6 +26,8 @@ function () {
var TestConstructorOnly =
/*#__PURE__*/
function (_ref2) {
"use strict";
babelHelpers.inherits(TestConstructorOnly, _ref2);
function TestConstructorOnly() {
@ -33,6 +39,8 @@ function (_ref2) {
}(
/*#__PURE__*/
function () {
"use strict";
function _class2() {
babelHelpers.classCallCheck(this, _class2);
}
@ -43,6 +51,8 @@ function () {
var TestMethodOnly =
/*#__PURE__*/
function (_ref3) {
"use strict";
babelHelpers.inherits(TestMethodOnly, _ref3);
function TestMethodOnly() {
@ -54,6 +64,8 @@ function (_ref3) {
}(
/*#__PURE__*/
function () {
"use strict";
function _class3() {
babelHelpers.classCallCheck(this, _class3);
}
@ -68,6 +80,8 @@ function () {
var TestConstructorAndMethod =
/*#__PURE__*/
function (_ref4) {
"use strict";
babelHelpers.inherits(TestConstructorAndMethod, _ref4);
function TestConstructorAndMethod() {
@ -79,6 +93,8 @@ function (_ref4) {
}(
/*#__PURE__*/
function () {
"use strict";
function _class4() {
babelHelpers.classCallCheck(this, _class4);
}
@ -93,6 +109,8 @@ function () {
var TestMultipleMethods =
/*#__PURE__*/
function (_ref5) {
"use strict";
babelHelpers.inherits(TestMultipleMethods, _ref5);
function TestMultipleMethods() {
@ -104,6 +122,8 @@ function (_ref5) {
}(
/*#__PURE__*/
function () {
"use strict";
function _class5() {
babelHelpers.classCallCheck(this, _class5);
}

View File

@ -1,6 +1,8 @@
var BaseController =
/*#__PURE__*/
function (_Chaplin$Controller) {
"use strict";
babelHelpers.inherits(BaseController, _Chaplin$Controller);
function BaseController() {
@ -14,6 +16,8 @@ function (_Chaplin$Controller) {
var BaseController2 =
/*#__PURE__*/
function (_Chaplin$Controller$A) {
"use strict";
babelHelpers.inherits(BaseController2, _Chaplin$Controller$A);
function BaseController2() {

View File

@ -1,6 +1,8 @@
var Test =
/*#__PURE__*/
function (_Foo) {
"use strict";
babelHelpers.inherits(Test, _Foo);
function Test() {

View File

@ -1,4 +1,6 @@
var Test = function Test() {
"use strict";
babelHelpers.classCallCheck(this, Test);
babelHelpers.get(babelHelpers.getPrototypeOf(Test.prototype), "hasOwnProperty", babelHelpers.assertThisInitialized(this)).call(this, "test");
};

View File

@ -15,6 +15,8 @@ function _assertThisInitialized(self) { if (self === void 0) { throw new Referen
var Foo =
/*#__PURE__*/
function (_Bar) {
"use strict";
_inherits(Foo, _Bar);
function Foo() {

View File

@ -15,6 +15,8 @@ function _assertThisInitialized(self) { if (self === void 0) { throw new Referen
var Foo =
/*#__PURE__*/
function (_Bar) {
"use strict";
_inherits(Foo, _Bar);
function Foo() {

Some files were not shown because too many files have changed in this diff Show More