Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

shift-ast

Package Overview
Dependencies
Maintainers
3
Versions
13
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

shift-ast - npm Package Compare versions

Comparing version 5.0.0 to 6.0.0

338

dist/index.js

@@ -461,3 +461,3 @@ 'use strict';

var ForInStatement = exports.ForInStatement = function ForInStatement(_ref41) {
var ForAwaitStatement = exports.ForAwaitStatement = function ForAwaitStatement(_ref41) {
var left = _ref41.left,

@@ -467,5 +467,5 @@ right = _ref41.right,

_classCallCheck(this, ForInStatement);
_classCallCheck(this, ForAwaitStatement);
this.type = 'ForInStatement';
this.type = 'ForAwaitStatement';
this.left = left;

@@ -476,3 +476,3 @@ this.right = right;

var ForOfStatement = exports.ForOfStatement = function ForOfStatement(_ref42) {
var ForInStatement = exports.ForInStatement = function ForInStatement(_ref42) {
var left = _ref42.left,

@@ -482,2 +482,15 @@ right = _ref42.right,

_classCallCheck(this, ForInStatement);
this.type = 'ForInStatement';
this.left = left;
this.right = right;
this.body = body;
};
var ForOfStatement = exports.ForOfStatement = function ForOfStatement(_ref43) {
var left = _ref43.left,
right = _ref43.right,
body = _ref43.body;
_classCallCheck(this, ForOfStatement);

@@ -491,7 +504,7 @@

var ForStatement = exports.ForStatement = function ForStatement(_ref43) {
var init = _ref43.init,
test = _ref43.test,
update = _ref43.update,
body = _ref43.body;
var ForStatement = exports.ForStatement = function ForStatement(_ref44) {
var init = _ref44.init,
test = _ref44.test,
update = _ref44.update,
body = _ref44.body;

@@ -507,5 +520,5 @@ _classCallCheck(this, ForStatement);

var FormalParameters = exports.FormalParameters = function FormalParameters(_ref44) {
var items = _ref44.items,
rest = _ref44.rest;
var FormalParameters = exports.FormalParameters = function FormalParameters(_ref45) {
var items = _ref45.items,
rest = _ref45.rest;

@@ -519,5 +532,5 @@ _classCallCheck(this, FormalParameters);

var FunctionBody = exports.FunctionBody = function FunctionBody(_ref45) {
var directives = _ref45.directives,
statements = _ref45.statements;
var FunctionBody = exports.FunctionBody = function FunctionBody(_ref46) {
var directives = _ref46.directives,
statements = _ref46.statements;

@@ -531,8 +544,8 @@ _classCallCheck(this, FunctionBody);

var FunctionDeclaration = exports.FunctionDeclaration = function FunctionDeclaration(_ref46) {
var isAsync = _ref46.isAsync,
isGenerator = _ref46.isGenerator,
name = _ref46.name,
params = _ref46.params,
body = _ref46.body;
var FunctionDeclaration = exports.FunctionDeclaration = function FunctionDeclaration(_ref47) {
var isAsync = _ref47.isAsync,
isGenerator = _ref47.isGenerator,
name = _ref47.name,
params = _ref47.params,
body = _ref47.body;

@@ -549,8 +562,8 @@ _classCallCheck(this, FunctionDeclaration);

var FunctionExpression = exports.FunctionExpression = function FunctionExpression(_ref47) {
var isAsync = _ref47.isAsync,
isGenerator = _ref47.isGenerator,
name = _ref47.name,
params = _ref47.params,
body = _ref47.body;
var FunctionExpression = exports.FunctionExpression = function FunctionExpression(_ref48) {
var isAsync = _ref48.isAsync,
isGenerator = _ref48.isGenerator,
name = _ref48.name,
params = _ref48.params,
body = _ref48.body;

@@ -567,5 +580,5 @@ _classCallCheck(this, FunctionExpression);

var Getter = exports.Getter = function Getter(_ref48) {
var name = _ref48.name,
body = _ref48.body;
var Getter = exports.Getter = function Getter(_ref49) {
var name = _ref49.name,
body = _ref49.body;

@@ -579,4 +592,4 @@ _classCallCheck(this, Getter);

var IdentifierExpression = exports.IdentifierExpression = function IdentifierExpression(_ref49) {
var name = _ref49.name;
var IdentifierExpression = exports.IdentifierExpression = function IdentifierExpression(_ref50) {
var name = _ref50.name;

@@ -589,6 +602,6 @@ _classCallCheck(this, IdentifierExpression);

var IfStatement = exports.IfStatement = function IfStatement(_ref50) {
var test = _ref50.test,
consequent = _ref50.consequent,
alternate = _ref50.alternate;
var IfStatement = exports.IfStatement = function IfStatement(_ref51) {
var test = _ref51.test,
consequent = _ref51.consequent,
alternate = _ref51.alternate;

@@ -603,6 +616,6 @@ _classCallCheck(this, IfStatement);

var Import = exports.Import = function Import(_ref51) {
var defaultBinding = _ref51.defaultBinding,
namedImports = _ref51.namedImports,
moduleSpecifier = _ref51.moduleSpecifier;
var Import = exports.Import = function Import(_ref52) {
var defaultBinding = _ref52.defaultBinding,
namedImports = _ref52.namedImports,
moduleSpecifier = _ref52.moduleSpecifier;

@@ -617,6 +630,6 @@ _classCallCheck(this, Import);

var ImportNamespace = exports.ImportNamespace = function ImportNamespace(_ref52) {
var defaultBinding = _ref52.defaultBinding,
namespaceBinding = _ref52.namespaceBinding,
moduleSpecifier = _ref52.moduleSpecifier;
var ImportNamespace = exports.ImportNamespace = function ImportNamespace(_ref53) {
var defaultBinding = _ref53.defaultBinding,
namespaceBinding = _ref53.namespaceBinding,
moduleSpecifier = _ref53.moduleSpecifier;

@@ -631,5 +644,5 @@ _classCallCheck(this, ImportNamespace);

var ImportSpecifier = exports.ImportSpecifier = function ImportSpecifier(_ref53) {
var name = _ref53.name,
binding = _ref53.binding;
var ImportSpecifier = exports.ImportSpecifier = function ImportSpecifier(_ref54) {
var name = _ref54.name,
binding = _ref54.binding;

@@ -643,5 +656,5 @@ _classCallCheck(this, ImportSpecifier);

var LabeledStatement = exports.LabeledStatement = function LabeledStatement(_ref54) {
var label = _ref54.label,
body = _ref54.body;
var LabeledStatement = exports.LabeledStatement = function LabeledStatement(_ref55) {
var label = _ref55.label,
body = _ref55.body;

@@ -655,4 +668,4 @@ _classCallCheck(this, LabeledStatement);

var LiteralBooleanExpression = exports.LiteralBooleanExpression = function LiteralBooleanExpression(_ref55) {
var value = _ref55.value;
var LiteralBooleanExpression = exports.LiteralBooleanExpression = function LiteralBooleanExpression(_ref56) {
var value = _ref56.value;

@@ -677,4 +690,4 @@ _classCallCheck(this, LiteralBooleanExpression);

var LiteralNumericExpression = exports.LiteralNumericExpression = function LiteralNumericExpression(_ref56) {
var value = _ref56.value;
var LiteralNumericExpression = exports.LiteralNumericExpression = function LiteralNumericExpression(_ref57) {
var value = _ref57.value;

@@ -687,9 +700,10 @@ _classCallCheck(this, LiteralNumericExpression);

var LiteralRegExpExpression = exports.LiteralRegExpExpression = function LiteralRegExpExpression(_ref57) {
var pattern = _ref57.pattern,
global = _ref57.global,
ignoreCase = _ref57.ignoreCase,
multiLine = _ref57.multiLine,
sticky = _ref57.sticky,
unicode = _ref57.unicode;
var LiteralRegExpExpression = exports.LiteralRegExpExpression = function LiteralRegExpExpression(_ref58) {
var pattern = _ref58.pattern,
global = _ref58.global,
ignoreCase = _ref58.ignoreCase,
multiLine = _ref58.multiLine,
dotAll = _ref58.dotAll,
unicode = _ref58.unicode,
sticky = _ref58.sticky;

@@ -703,8 +717,9 @@ _classCallCheck(this, LiteralRegExpExpression);

this.multiLine = multiLine;
this.dotAll = dotAll;
this.unicode = unicode;
this.sticky = sticky;
this.unicode = unicode;
};
var LiteralStringExpression = exports.LiteralStringExpression = function LiteralStringExpression(_ref58) {
var value = _ref58.value;
var LiteralStringExpression = exports.LiteralStringExpression = function LiteralStringExpression(_ref59) {
var value = _ref59.value;

@@ -717,8 +732,8 @@ _classCallCheck(this, LiteralStringExpression);

var Method = exports.Method = function Method(_ref59) {
var isAsync = _ref59.isAsync,
isGenerator = _ref59.isGenerator,
name = _ref59.name,
params = _ref59.params,
body = _ref59.body;
var Method = exports.Method = function Method(_ref60) {
var isAsync = _ref60.isAsync,
isGenerator = _ref60.isGenerator,
name = _ref60.name,
params = _ref60.params,
body = _ref60.body;

@@ -735,5 +750,5 @@ _classCallCheck(this, Method);

var Module = exports.Module = function Module(_ref60) {
var directives = _ref60.directives,
items = _ref60.items;
var Module = exports.Module = function Module(_ref61) {
var directives = _ref61.directives,
items = _ref61.items;

@@ -747,5 +762,5 @@ _classCallCheck(this, Module);

var NewExpression = exports.NewExpression = function NewExpression(_ref61) {
var callee = _ref61.callee,
_arguments = _ref61.arguments;
var NewExpression = exports.NewExpression = function NewExpression(_ref62) {
var callee = _ref62.callee,
_arguments = _ref62.arguments;

@@ -765,4 +780,5 @@ _classCallCheck(this, NewExpression);

var ObjectAssignmentTarget = exports.ObjectAssignmentTarget = function ObjectAssignmentTarget(_ref62) {
var properties = _ref62.properties;
var ObjectAssignmentTarget = exports.ObjectAssignmentTarget = function ObjectAssignmentTarget(_ref63) {
var properties = _ref63.properties,
rest = _ref63.rest;

@@ -773,6 +789,8 @@ _classCallCheck(this, ObjectAssignmentTarget);

this.properties = properties;
this.rest = rest;
};
var ObjectBinding = exports.ObjectBinding = function ObjectBinding(_ref63) {
var properties = _ref63.properties;
var ObjectBinding = exports.ObjectBinding = function ObjectBinding(_ref64) {
var properties = _ref64.properties,
rest = _ref64.rest;

@@ -783,6 +801,7 @@ _classCallCheck(this, ObjectBinding);

this.properties = properties;
this.rest = rest;
};
var ObjectExpression = exports.ObjectExpression = function ObjectExpression(_ref64) {
var properties = _ref64.properties;
var ObjectExpression = exports.ObjectExpression = function ObjectExpression(_ref65) {
var properties = _ref65.properties;

@@ -795,4 +814,4 @@ _classCallCheck(this, ObjectExpression);

var ReturnStatement = exports.ReturnStatement = function ReturnStatement(_ref65) {
var expression = _ref65.expression;
var ReturnStatement = exports.ReturnStatement = function ReturnStatement(_ref66) {
var expression = _ref66.expression;

@@ -805,5 +824,5 @@ _classCallCheck(this, ReturnStatement);

var Script = exports.Script = function Script(_ref66) {
var directives = _ref66.directives,
statements = _ref66.statements;
var Script = exports.Script = function Script(_ref67) {
var directives = _ref67.directives,
statements = _ref67.statements;

@@ -817,6 +836,6 @@ _classCallCheck(this, Script);

var Setter = exports.Setter = function Setter(_ref67) {
var name = _ref67.name,
param = _ref67.param,
body = _ref67.body;
var Setter = exports.Setter = function Setter(_ref68) {
var name = _ref68.name,
param = _ref68.param,
body = _ref68.body;

@@ -831,4 +850,4 @@ _classCallCheck(this, Setter);

var ShorthandProperty = exports.ShorthandProperty = function ShorthandProperty(_ref68) {
var name = _ref68.name;
var ShorthandProperty = exports.ShorthandProperty = function ShorthandProperty(_ref69) {
var name = _ref69.name;

@@ -841,4 +860,4 @@ _classCallCheck(this, ShorthandProperty);

var SpreadElement = exports.SpreadElement = function SpreadElement(_ref69) {
var expression = _ref69.expression;
var SpreadElement = exports.SpreadElement = function SpreadElement(_ref70) {
var expression = _ref70.expression;

@@ -851,6 +870,15 @@ _classCallCheck(this, SpreadElement);

var StaticMemberAssignmentTarget = exports.StaticMemberAssignmentTarget = function StaticMemberAssignmentTarget(_ref70) {
var object = _ref70.object,
property = _ref70.property;
var SpreadProperty = exports.SpreadProperty = function SpreadProperty(_ref71) {
var expression = _ref71.expression;
_classCallCheck(this, SpreadProperty);
this.type = 'SpreadProperty';
this.expression = expression;
};
var StaticMemberAssignmentTarget = exports.StaticMemberAssignmentTarget = function StaticMemberAssignmentTarget(_ref72) {
var object = _ref72.object,
property = _ref72.property;
_classCallCheck(this, StaticMemberAssignmentTarget);

@@ -863,5 +891,5 @@

var StaticMemberExpression = exports.StaticMemberExpression = function StaticMemberExpression(_ref71) {
var object = _ref71.object,
property = _ref71.property;
var StaticMemberExpression = exports.StaticMemberExpression = function StaticMemberExpression(_ref73) {
var object = _ref73.object,
property = _ref73.property;

@@ -875,4 +903,4 @@ _classCallCheck(this, StaticMemberExpression);

var StaticPropertyName = exports.StaticPropertyName = function StaticPropertyName(_ref72) {
var value = _ref72.value;
var StaticPropertyName = exports.StaticPropertyName = function StaticPropertyName(_ref74) {
var value = _ref74.value;

@@ -891,5 +919,5 @@ _classCallCheck(this, StaticPropertyName);

var SwitchCase = exports.SwitchCase = function SwitchCase(_ref73) {
var test = _ref73.test,
consequent = _ref73.consequent;
var SwitchCase = exports.SwitchCase = function SwitchCase(_ref75) {
var test = _ref75.test,
consequent = _ref75.consequent;

@@ -903,4 +931,4 @@ _classCallCheck(this, SwitchCase);

var SwitchDefault = exports.SwitchDefault = function SwitchDefault(_ref74) {
var consequent = _ref74.consequent;
var SwitchDefault = exports.SwitchDefault = function SwitchDefault(_ref76) {
var consequent = _ref76.consequent;

@@ -913,5 +941,5 @@ _classCallCheck(this, SwitchDefault);

var SwitchStatement = exports.SwitchStatement = function SwitchStatement(_ref75) {
var discriminant = _ref75.discriminant,
cases = _ref75.cases;
var SwitchStatement = exports.SwitchStatement = function SwitchStatement(_ref77) {
var discriminant = _ref77.discriminant,
cases = _ref77.cases;

@@ -925,7 +953,7 @@ _classCallCheck(this, SwitchStatement);

var SwitchStatementWithDefault = exports.SwitchStatementWithDefault = function SwitchStatementWithDefault(_ref76) {
var discriminant = _ref76.discriminant,
preDefaultCases = _ref76.preDefaultCases,
defaultCase = _ref76.defaultCase,
postDefaultCases = _ref76.postDefaultCases;
var SwitchStatementWithDefault = exports.SwitchStatementWithDefault = function SwitchStatementWithDefault(_ref78) {
var discriminant = _ref78.discriminant,
preDefaultCases = _ref78.preDefaultCases,
defaultCase = _ref78.defaultCase,
postDefaultCases = _ref78.postDefaultCases;

@@ -941,4 +969,4 @@ _classCallCheck(this, SwitchStatementWithDefault);

var TemplateElement = exports.TemplateElement = function TemplateElement(_ref77) {
var rawValue = _ref77.rawValue;
var TemplateElement = exports.TemplateElement = function TemplateElement(_ref79) {
var rawValue = _ref79.rawValue;

@@ -951,5 +979,5 @@ _classCallCheck(this, TemplateElement);

var TemplateExpression = exports.TemplateExpression = function TemplateExpression(_ref78) {
var tag = _ref78.tag,
elements = _ref78.elements;
var TemplateExpression = exports.TemplateExpression = function TemplateExpression(_ref80) {
var tag = _ref80.tag,
elements = _ref80.elements;

@@ -969,4 +997,4 @@ _classCallCheck(this, TemplateExpression);

var ThrowStatement = exports.ThrowStatement = function ThrowStatement(_ref79) {
var expression = _ref79.expression;
var ThrowStatement = exports.ThrowStatement = function ThrowStatement(_ref81) {
var expression = _ref81.expression;

@@ -979,5 +1007,5 @@ _classCallCheck(this, ThrowStatement);

var TryCatchStatement = exports.TryCatchStatement = function TryCatchStatement(_ref80) {
var body = _ref80.body,
catchClause = _ref80.catchClause;
var TryCatchStatement = exports.TryCatchStatement = function TryCatchStatement(_ref82) {
var body = _ref82.body,
catchClause = _ref82.catchClause;

@@ -991,6 +1019,6 @@ _classCallCheck(this, TryCatchStatement);

var TryFinallyStatement = exports.TryFinallyStatement = function TryFinallyStatement(_ref81) {
var body = _ref81.body,
catchClause = _ref81.catchClause,
finalizer = _ref81.finalizer;
var TryFinallyStatement = exports.TryFinallyStatement = function TryFinallyStatement(_ref83) {
var body = _ref83.body,
catchClause = _ref83.catchClause,
finalizer = _ref83.finalizer;

@@ -1005,5 +1033,5 @@ _classCallCheck(this, TryFinallyStatement);

var UnaryExpression = exports.UnaryExpression = function UnaryExpression(_ref82) {
var operator = _ref82.operator,
operand = _ref82.operand;
var UnaryExpression = exports.UnaryExpression = function UnaryExpression(_ref84) {
var operator = _ref84.operator,
operand = _ref84.operand;

@@ -1017,6 +1045,6 @@ _classCallCheck(this, UnaryExpression);

var UpdateExpression = exports.UpdateExpression = function UpdateExpression(_ref83) {
var isPrefix = _ref83.isPrefix,
operator = _ref83.operator,
operand = _ref83.operand;
var UpdateExpression = exports.UpdateExpression = function UpdateExpression(_ref85) {
var isPrefix = _ref85.isPrefix,
operator = _ref85.operator,
operand = _ref85.operand;

@@ -1031,5 +1059,5 @@ _classCallCheck(this, UpdateExpression);

var VariableDeclaration = exports.VariableDeclaration = function VariableDeclaration(_ref84) {
var kind = _ref84.kind,
declarators = _ref84.declarators;
var VariableDeclaration = exports.VariableDeclaration = function VariableDeclaration(_ref86) {
var kind = _ref86.kind,
declarators = _ref86.declarators;

@@ -1043,4 +1071,4 @@ _classCallCheck(this, VariableDeclaration);

var VariableDeclarationStatement = exports.VariableDeclarationStatement = function VariableDeclarationStatement(_ref85) {
var declaration = _ref85.declaration;
var VariableDeclarationStatement = exports.VariableDeclarationStatement = function VariableDeclarationStatement(_ref87) {
var declaration = _ref87.declaration;

@@ -1053,5 +1081,5 @@ _classCallCheck(this, VariableDeclarationStatement);

var VariableDeclarator = exports.VariableDeclarator = function VariableDeclarator(_ref86) {
var binding = _ref86.binding,
init = _ref86.init;
var VariableDeclarator = exports.VariableDeclarator = function VariableDeclarator(_ref88) {
var binding = _ref88.binding,
init = _ref88.init;

@@ -1065,5 +1093,5 @@ _classCallCheck(this, VariableDeclarator);

var WhileStatement = exports.WhileStatement = function WhileStatement(_ref87) {
var test = _ref87.test,
body = _ref87.body;
var WhileStatement = exports.WhileStatement = function WhileStatement(_ref89) {
var test = _ref89.test,
body = _ref89.body;

@@ -1077,5 +1105,5 @@ _classCallCheck(this, WhileStatement);

var WithStatement = exports.WithStatement = function WithStatement(_ref88) {
var object = _ref88.object,
body = _ref88.body;
var WithStatement = exports.WithStatement = function WithStatement(_ref90) {
var object = _ref90.object,
body = _ref90.body;

@@ -1089,4 +1117,4 @@ _classCallCheck(this, WithStatement);

var YieldExpression = exports.YieldExpression = function YieldExpression(_ref89) {
var expression = _ref89.expression;
var YieldExpression = exports.YieldExpression = function YieldExpression(_ref91) {
var expression = _ref91.expression;

@@ -1099,4 +1127,4 @@ _classCallCheck(this, YieldExpression);

var YieldGeneratorExpression = exports.YieldGeneratorExpression = function YieldGeneratorExpression(_ref90) {
var expression = _ref90.expression;
var YieldGeneratorExpression = exports.YieldGeneratorExpression = function YieldGeneratorExpression(_ref92) {
var expression = _ref92.expression;

@@ -1103,0 +1131,0 @@ _classCallCheck(this, YieldGeneratorExpression);

{
"name": "shift-ast",
"version": "5.0.0",
"version": "6.0.0",
"description": "constructors for the Shift AST format",

@@ -29,3 +29,3 @@ "author": "Shape Security",

"mocha": "^5.2.0",
"shift-spec": "2017.0.0"
"shift-spec": "2018.0.2"
},

@@ -32,0 +32,0 @@ "keywords": [

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

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc