@babel/helper-replace-supers
Advanced tools
Comparing version 7.0.0-beta.34 to 7.0.0-beta.35
@@ -94,2 +94,3 @@ "use strict"; | ||
this.inClass = void 0; | ||
this.inConstructor = void 0; | ||
this.isLoose = void 0; | ||
@@ -106,2 +107,3 @@ this.scope = void 0; | ||
this.inClass = inClass; | ||
this.inConstructor = opts.inConstructor; | ||
this.isLoose = opts.isLoose; | ||
@@ -127,3 +129,9 @@ this.scope = this.methodPath.scope; | ||
_proto.getSuperProperty = function getSuperProperty(property, isComputed) { | ||
return t.callExpression(this.file.addHelper("get"), [getPrototypeOfExpression(this.getObjectRef(), this.isStatic), isComputed ? property : t.stringLiteral(property.name), t.thisExpression()]); | ||
var thisExpr = t.thisExpression(); | ||
if (this.inConstructor) { | ||
thisExpr = t.callExpression(this.file.addHelper("assertThisInitialized"), [thisExpr]); | ||
} | ||
return t.callExpression(this.file.addHelper("get"), [getPrototypeOfExpression(this.getObjectRef(), this.isStatic), isComputed ? property : t.stringLiteral(property.name), thisExpr]); | ||
}; | ||
@@ -130,0 +138,0 @@ |
{ | ||
"name": "@babel/helper-replace-supers", | ||
"version": "7.0.0-beta.34", | ||
"version": "7.0.0-beta.35", | ||
"description": "Helper function to replace supers", | ||
@@ -9,7 +9,7 @@ "repository": "https://github.com/babel/babel/tree/master/packages/babel-helper-replace-supers", | ||
"dependencies": { | ||
"@babel/helper-optimise-call-expression": "7.0.0-beta.34", | ||
"@babel/template": "7.0.0-beta.34", | ||
"@babel/traverse": "7.0.0-beta.34", | ||
"@babel/types": "7.0.0-beta.34" | ||
"@babel/helper-optimise-call-expression": "7.0.0-beta.35", | ||
"@babel/template": "7.0.0-beta.35", | ||
"@babel/traverse": "7.0.0-beta.35", | ||
"@babel/types": "7.0.0-beta.35" | ||
} | ||
} |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
8523
199
+ Added@babel/code-frame@7.0.0-beta.35(transitive)
+ Added@babel/helper-function-name@7.0.0-beta.35(transitive)
+ Added@babel/helper-get-function-arity@7.0.0-beta.35(transitive)
+ Added@babel/helper-optimise-call-expression@7.0.0-beta.35(transitive)
+ Added@babel/template@7.0.0-beta.35(transitive)
+ Added@babel/traverse@7.0.0-beta.35(transitive)
+ Added@babel/types@7.0.0-beta.35(transitive)
+ Addedbabylon@7.0.0-beta.35(transitive)
- Removed@babel/code-frame@7.0.0-beta.34(transitive)
- Removed@babel/helper-function-name@7.0.0-beta.34(transitive)
- Removed@babel/helper-get-function-arity@7.0.0-beta.34(transitive)
- Removed@babel/helper-optimise-call-expression@7.0.0-beta.34(transitive)
- Removed@babel/template@7.0.0-beta.34(transitive)
- Removed@babel/traverse@7.0.0-beta.34(transitive)
- Removed@babel/types@7.0.0-beta.34(transitive)
- Removedbabylon@7.0.0-beta.34(transitive)
Updated@babel/types@7.0.0-beta.35