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

ret

Package Overview
Dependencies
Maintainers
1
Versions
27
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

ret - npm Package Compare versions

Comparing version 0.1.0 to 0.1.1

9

lib/util.js

@@ -47,3 +47,3 @@ var types = require('./types')

var tokens = []
, regexp = /\\(?:(w)|(d)|(s)|(.))|(\.)|(.-.)|(\])|(.)/g
, regexp = /\\(?:(w)|(d)|(s)|(.))|(.-[^\]])|(\])|(.)/g
, rs, c

@@ -63,3 +63,3 @@ ;

} else if (c = rs[4] || rs[8]) {
} else if (c = rs[4] || rs[7]) {
tokens.push({

@@ -70,6 +70,3 @@ type: types.CHAR

} else if (rs[5]) {
tokens.push(classes.anyChar());
} else if (c = rs[6]) {
} else if (c = rs[5]) {
tokens.push({

@@ -76,0 +73,0 @@ type: types.RANGE

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

"keywords": ["regex", "regexp", "regular expression", "parser", "tokenizer"],
"version": "0.1.0",
"version": "0.1.1",
"repository": {

@@ -8,0 +8,0 @@ "type": "git",

@@ -30,3 +30,3 @@ var vows = require('vows')

topic: function() {
return util.tokenizeClass('\\w\\d$\\s\\]\\B.] will ignore');
return util.tokenizeClass('\\w\\d$\\s\\]\\B.+-] will ignore');
},

@@ -56,5 +56,7 @@

'Get an any character class token': function(t) {
'Get correct char tokens at end of class': function(t) {
assert.isArray(t[0]);
assert.deepEqual(t[0][6], classes.anyChar());
assert.deepEqual(t[0][6], { type: types.CHAR, value: 46 });
assert.deepEqual(t[0][7], { type: types.CHAR, value: 43 });
assert.deepEqual(t[0][8], { type: types.CHAR, value: 45 });
},

@@ -64,3 +66,3 @@

assert.isNumber(t[1]);
assert.equal(t[1], 13);
assert.equal(t[1], 15);
}

@@ -67,0 +69,0 @@ },

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