You're Invited:Meet the Socket Team at RSAC and BSidesSF 2026, March 23–26.RSVP
Socket
Book a DemoSign in
Socket

@babel/plugin-transform-regenerator

Package Overview
Dependencies
Maintainers
4
Versions
108
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@babel/plugin-transform-regenerator - npm Package Compare versions

Comparing version
7.27.4
to
7.27.5
+10
-4
lib/regenerator/emit.js

@@ -36,3 +36,3 @@ "use strict";

this.returns = void 0;
this.lastDefaultIndex = void 0;
this.lastReferenceIndex = 0;
this.marked = void 0;

@@ -55,2 +55,3 @@ this.insertedLocs = void 0;

this.returns = new Set();
this.lastReferenceIndex = 0;
this.marked = [true];

@@ -86,2 +87,5 @@ this.insertedLocs = new Set();

this.marked[this.listing.length] = true;
if (loc.value > this.lastReferenceIndex) {
this.lastReferenceIndex = loc.value;
}
return loc;

@@ -159,3 +163,3 @@ }

if (util.newHelpersAvailable(this.pluginPass)) {
if (this.lastDefaultIndex === this.index || !this.returns.has(this.listing.length)) {
if (this.lastReferenceIndex === this.index || !this.returns.has(this.listing.length)) {
cases.push(_core.types.switchCase(this.finalLoc, [_core.types.returnStatement(_core.types.callExpression(this.contextProperty("a"), [_core.types.numericLiteral(2)]))]));

@@ -338,3 +342,2 @@ }

_assert.strictEqual(after.value, defaultLoc.value);
this.lastDefaultIndex = this.index;
}

@@ -375,4 +378,7 @@ break;

if (catchLoc) {
const body = path.node.block.body;
if (finallyLoc) {
self.jump(finallyLoc);
} else if (body.length && body[body.length - 1].type === "ReturnStatement") {
after = null;
} else {

@@ -405,3 +411,3 @@ self.jump(after);

});
self.mark(after);
if (after) self.mark(after);
break;

@@ -408,0 +414,0 @@ case "ThrowStatement":

@@ -5,3 +5,3 @@ {

"description": "Explode async and generator functions into a state machine.",
"version": "7.27.4",
"version": "7.27.5",
"homepage": "https://babel.dev/docs/en/next/babel-plugin-transform-regenerator",

@@ -30,3 +30,3 @@ "repository": {

"@babel/plugin-transform-arrow-functions": "^7.27.1",
"@babel/plugin-transform-block-scoping": "^7.27.3",
"@babel/plugin-transform-block-scoping": "^7.27.5",
"@babel/plugin-transform-classes": "^7.27.1",

@@ -33,0 +33,0 @@ "@babel/plugin-transform-for-of": "^7.27.1",

Sorry, the diff of this file is too big to display