decaffeinate-parser
Advanced tools
Comparing version 21.0.1 to 21.0.2
@@ -183,2 +183,5 @@ "use strict"; | ||
}(nodes_2.BinaryOp)); | ||
function tokenStartsWith(prefix, context, token) { | ||
return context.source.slice(token.start, token.start + prefix.length) === prefix; | ||
} | ||
function mapNegateableBinaryOp(context, node, Op) { | ||
@@ -193,3 +196,3 @@ var _a = mapBinaryOp(context, node, TemporaryBinaryOp), line = _a.line, column = _a.column, start = _a.start, end = _a.end, raw = _a.raw, left = _a.left, right = _a.right; | ||
if (token && (token.type === coffee_lex_1.SourceType.OPERATOR || token.type === coffee_lex_1.SourceType.RELATION)) { | ||
isNot = context.source.slice(token.start, token.start + 'not'.length) === 'not'; | ||
isNot = tokenStartsWith('not', context, token) || tokenStartsWith('!', context, token); | ||
break; | ||
@@ -196,0 +199,0 @@ } |
@@ -1,1 +0,1 @@ | ||
{"name":"decaffeinate-parser","description":"A better AST for CoffeeScript, inspired by CoffeeScriptRedux.","version":"21.0.1","main":"dist/parser.js","module":"dist/parser.mjs","types":"dist/parser.d.ts","scripts":{"build":"./script/build","lint":"eslint src test && tslint --config tslint.json --project tsconfig.json","lint-fix":"eslint src test --fix && tslint --config tslint.json --project tsconfig.json --fix","pretest":"npm run lint","test":"mocha"},"keywords":["coffeescript","ast","parse"],"author":"Brian Donovan","license":"MIT","files":["dist/"],"engines":{"node":">=6"},"dependencies":{"babylon":"^6.18.0","coffee-lex":"^8.1.1","decaffeinate-coffeescript":"1.12.7-patch.2","decaffeinate-coffeescript2":"2.2.1-patch.1","json-stable-stringify":"^1.0.1","lines-and-columns":"^1.1.6"},"devDependencies":{"@types/babylon":"^6.16.2","@types/json-stable-stringify":"^1.0.32","@types/mocha":"^2.2.46","@types/node":"9.4.6","babel":"^6.5.2","babel-eslint":"^8.2.1","babel-plugin-external-helpers":"^6.8.0","babel-plugin-object-rest-spread":"0.0.0","babel-plugin-syntax-flow":"^6.8.0","babel-plugin-syntax-object-rest-spread":"^6.8.0","babel-plugin-transform-flow-strip-types":"^6.21.0","babel-plugin-transform-object-rest-spread":"^6.26.0","babel-preset-es2015":"^6.13.0","babel-register":"^6.26.0","coffee-script-redux":"^2.0.0-beta8","eslint":"^4.15.0","mocha":"^5.0.0","semantic-release":"^8.2.0","string-repeat":"^1.1.1","ts-node":"^4.1.0","tslint":"^5.8.0","typescript":"^2.6.2"},"publishConfig":{"registry":"https://registry.npmjs.org/"},"repository":{"type":"git","url":"https://github.com/decaffeinate/decaffeinate-parser.git"}} | ||
{"name":"decaffeinate-parser","description":"A better AST for CoffeeScript, inspired by CoffeeScriptRedux.","version":"21.0.2","main":"dist/parser.js","module":"dist/parser.mjs","types":"dist/parser.d.ts","scripts":{"build":"./script/build","lint":"eslint src test && tslint --config tslint.json --project tsconfig.json","lint-fix":"eslint src test --fix && tslint --config tslint.json --project tsconfig.json --fix","pretest":"npm run lint","test":"mocha"},"keywords":["coffeescript","ast","parse"],"author":"Brian Donovan","license":"MIT","files":["dist/"],"engines":{"node":">=6"},"dependencies":{"babylon":"^6.18.0","coffee-lex":"^8.1.2","decaffeinate-coffeescript":"1.12.7-patch.2","decaffeinate-coffeescript2":"2.2.1-patch.1","json-stable-stringify":"^1.0.1","lines-and-columns":"^1.1.6"},"devDependencies":{"@types/babylon":"^6.16.2","@types/json-stable-stringify":"^1.0.32","@types/mocha":"^2.2.46","@types/node":"9.4.6","babel":"^6.5.2","babel-eslint":"^8.2.1","babel-plugin-external-helpers":"^6.8.0","babel-plugin-object-rest-spread":"0.0.0","babel-plugin-syntax-flow":"^6.8.0","babel-plugin-syntax-object-rest-spread":"^6.8.0","babel-plugin-transform-flow-strip-types":"^6.21.0","babel-plugin-transform-object-rest-spread":"^6.26.0","babel-preset-es2015":"^6.13.0","babel-register":"^6.26.0","coffee-script-redux":"^2.0.0-beta8","eslint":"^4.15.0","mocha":"^5.0.0","semantic-release":"^8.2.0","string-repeat":"^1.1.1","ts-node":"^4.1.0","tslint":"^5.8.0","typescript":"^2.6.2"},"publishConfig":{"registry":"https://registry.npmjs.org/"},"repository":{"type":"git","url":"https://github.com/decaffeinate/decaffeinate-parser.git"}} |
Sorry, the diff of this file is not supported yet
368905
8308
Updatedcoffee-lex@^8.1.2