pegjs-util
Advanced tools
Comparing version 0.9.2 to 0.9.3
{ | ||
"name": "pegjs-util", | ||
"version": "0.9.2", | ||
"version": "0.9.3", | ||
"description": "Utility Class for PEG.js", | ||
@@ -5,0 +5,0 @@ "main": "PEGUtil.js", |
{ | ||
"name": "pegjs-util", | ||
"version": "0.9.2", | ||
"version": "0.9.3", | ||
"description": "Utility Class for PEG.js", | ||
@@ -5,0 +5,0 @@ "keywords": [ "pegjs", "parser", "AST", "unroll" ], |
@@ -110,5 +110,7 @@ /* | ||
set: function () { | ||
var self = this; | ||
if (arguments.length === 1 && typeof arguments[0] === "object") | ||
Object.keys(arguments[0]).forEach(function (key) { self.A[key] = arguments[0][key]; }); | ||
if (arguments.length === 1 && typeof arguments[0] === "object") { | ||
var self = this; | ||
var args = arguments; | ||
Object.keys(args[0]).forEach(function (key) { self.A[key] = args[0][key]; }); | ||
} | ||
else if (arguments.length === 2) | ||
@@ -136,3 +138,3 @@ this.A[arguments[0]] = arguments[1]; | ||
if (arguments.length === 0) | ||
throw new Error("add: invalid argument"); | ||
throw new Error("add: missing argument(s)"); | ||
var _add = function (C, node) { | ||
@@ -223,6 +225,6 @@ if (!((typeof node === "object") && | ||
else | ||
out += value.toString(); | ||
out += JSON.stringify(value); | ||
break; | ||
default: | ||
out += value.toString(); | ||
out += JSON.stringify(value); | ||
break; | ||
@@ -229,0 +231,0 @@ } |
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
32822
578