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

clarinet

Package Overview
Dependencies
Maintainers
2
Versions
30
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

clarinet - npm Package Compare versions

Comparing version 0.10.0 to 0.11.0

test/position.js

21

clarinet.js

@@ -327,3 +327,3 @@ ;(function (clarinet) {

error(parser, "Unexpected end");
closeValue(parser);

@@ -379,5 +379,5 @@ parser.c = "";

emit(parser, 'onopenobject');
this.depth++;
this.depth++;
emit(parser, 'oncloseobject');
this.depth--;
this.depth--;
parser.state = parser.stack.pop() || S.VALUE;

@@ -403,4 +403,4 @@ continue;

} else if (c==='}') {
emitNode(parser, 'oncloseobject');
this.depth--;
emitNode(parser, 'oncloseobject');
this.depth--;
parser.state = parser.stack.pop() || S.VALUE;

@@ -424,3 +424,3 @@ } else if(c===',') {

emit(parser, 'onclosearray');
this.depth--;
this.depth--;
parser.state = parser.stack.pop() || S.VALUE;

@@ -456,3 +456,3 @@ continue;

emitNode(parser, 'onclosearray');
this.depth--;
this.depth--;
parser.state = parser.stack.pop() || S.VALUE;

@@ -478,2 +478,3 @@ } else if (c === '\r' || c === '\n' || c === ' ' || c === '\t')

c = chunk.charAt(i++);
parser.position++;
if (unicodeI === 4) {

@@ -493,2 +494,3 @@ // TODO this might be slow? well, probably not used too often anyway

parser.textNode += chunk.substring(starti, i-1);
parser.position += i - 1 - starti;
if(!parser.textNode) {

@@ -502,3 +504,5 @@ emit(parser, "onvalue", "");

parser.textNode += chunk.substring(starti, i-1);
parser.position += i - 1 - starti;
c = chunk.charAt(i++);
parser.position++;
if (!c) break;

@@ -521,2 +525,3 @@ }

c = chunk.charAt(i++);
parser.position++;
starti = i-1;

@@ -532,2 +537,3 @@ if (!c) break;

parser.textNode += chunk.substring(starti, i-1);
parser.position += i - 1 - starti;
break;

@@ -539,2 +545,3 @@ }

parser.textNode += chunk.substring(starti, i-1);
parser.position += i - 1 - starti;
break;

@@ -541,0 +548,0 @@ }

@@ -11,3 +11,3 @@ {

],
"version": "0.10.0",
"version": "0.11.0",
"main": "./clarinet.js",

@@ -41,3 +41,3 @@ "homepage": "https://github.com/dscape/clarinet",

"scripts": {
"test": "./node_modules/mocha/bin/mocha -r should -t 10000 -s 2000 test/clarinet.js test/npm.js test/utf8-chunks.js"
"test": "./node_modules/mocha/bin/mocha -r should -t 10000 -s 2000 test/clarinet.js test/npm.js test/utf8-chunks.js test/position.js"
},

@@ -44,0 +44,0 @@ "engines": {

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