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

ast-types

Package Overview
Dependencies
Maintainers
1
Versions
172
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

ast-types - npm Package Compare versions

Comparing version 0.3.28 to 0.3.29

4

def/core.js

@@ -171,3 +171,3 @@ var types = require("../lib/types");

.bases("Function", "Declaration")
.build("id", "params", "body", "generator", "expression", "async")
.build("id", "params", "body", "generator", "expression")
.field("id", def("Identifier"));

@@ -177,3 +177,3 @@

.bases("Function", "Expression")
.build("id", "params", "body", "generator", "expression", "async");
.build("id", "params", "body", "generator", "expression");

@@ -180,0 +180,0 @@ def("VariableDeclaration")

@@ -5,2 +5,3 @@ var assert = require("assert");

var namedTypes = types.namedTypes;
var builders = types.builders;
var Node = namedTypes.Node;

@@ -64,2 +65,16 @@ var isArray = types.builtInTypes.array;

Sp.declareTemporary = function(prefix) {
assert.ok(/^[a-z$_]/i.test(prefix), prefix);
this.scan();
var index = 0;
while (this.declares(prefix + index)) {
++index;
}
var id = builders.identifier(prefix + index);
this.bindings[prefix + index] = id;
return id;
};
Sp.scan = function(force) {

@@ -66,0 +81,0 @@ if (force || !this.didScan) {

@@ -21,3 +21,3 @@ {

],
"version": "0.3.28",
"version": "0.3.29",
"homepage": "http://github.com/benjamn/ast-types",

@@ -24,0 +24,0 @@ "repository": {

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