tree-sitter-cpp
Advanced tools
Comparing version 0.20.5 to 0.21.0
@@ -1,19 +0,7 @@ | ||
try { | ||
module.exports = require("../../build/Release/tree_sitter_cpp_binding"); | ||
} catch (error1) { | ||
if (error1.code !== 'MODULE_NOT_FOUND') { | ||
throw error1; | ||
} | ||
try { | ||
module.exports = require("../../build/Debug/tree_sitter_cpp_binding"); | ||
} catch (error2) { | ||
if (error2.code !== 'MODULE_NOT_FOUND') { | ||
throw error2; | ||
} | ||
throw error1 | ||
} | ||
} | ||
const root = require("path").join(__dirname, "..", ".."); | ||
module.exports = require("node-gyp-build")(root); | ||
try { | ||
module.exports.nodeTypeInfo = require("../../src/node-types.json"); | ||
} catch (_) {} |
/** | ||
* @file C++ grammar for tree-sitter | ||
* @author Max Brunsfeld | ||
* @author Max Brunsfeld <maxbrunsfeld@gmail.com> | ||
* @author Amaan Qureshi <amaanq12@gmail.com> | ||
* @author John Drouhard <john@drouhard.dev> | ||
* @license MIT | ||
*/ | ||
/* eslint-disable arrow-parens */ | ||
/* eslint-disable camelcase */ | ||
/* eslint-disable-next-line spaced-comment */ | ||
/// <reference types="tree-sitter-cli/dsl" /> | ||
@@ -11,0 +10,0 @@ // @ts-check |
104
package.json
{ | ||
"name": "tree-sitter-cpp", | ||
"version": "0.20.5", | ||
"version": "0.21.0", | ||
"description": "C++ grammar for tree-sitter", | ||
"repository": "github:tree-sitter/tree-sitter-cpp", | ||
"license": "MIT", | ||
"author": "Max Brunsfeld <maxbrunsfeld@gmail.com>", | ||
"contributors": [ | ||
"Amaan Qureshi <amaanq12@gmail.com>" | ||
], | ||
"main": "bindings/node", | ||
"types": "bindings/node", | ||
"keywords": [ | ||
"parser", | ||
"incremental", | ||
"parsing", | ||
"tree-sitter", | ||
"c++" | ||
], | ||
"repository": { | ||
"type": "git", | ||
"url": "https://github.com/tree-sitter/tree-sitter-cpp.git" | ||
}, | ||
"author": "Max Brunsfeld", | ||
"license": "MIT", | ||
"files": [ | ||
"grammar.js", | ||
"binding.gyp", | ||
"prebuilds/**", | ||
"bindings/node/*", | ||
"queries/*", | ||
"src/**" | ||
], | ||
"dependencies": { | ||
"nan": "^2.18.0" | ||
"node-addon-api": "^8.0.0", | ||
"node-gyp-build": "^4.8.0" | ||
}, | ||
"peerDependencies": { | ||
"tree-sitter": "^0.21.1" | ||
}, | ||
"peerDependenciesMeta": { | ||
"tree_sitter": { | ||
"optional": true | ||
} | ||
}, | ||
"devDependencies": { | ||
"eslint": "^8.56.0", | ||
"eslint": "^8.57.0", | ||
"eslint-config-google": "^0.14.0", | ||
"tree-sitter-c": "^0.20.8", | ||
"tree-sitter-cli": "^0.20.8", | ||
"node-gyp": "^10.0.1" | ||
"node-gyp": "^10.0.1", | ||
"tree-sitter-c": "^0.21.0", | ||
"tree-sitter-cli": "^0.22.2", | ||
"prebuildify": "^6.0.0" | ||
}, | ||
"scripts": { | ||
"build": "tree-sitter generate && node-gyp build", | ||
"install": "node-gyp-build", | ||
"prebuildify": "prebuildify --napi --strip", | ||
"build": "tree-sitter generate --no-bindings", | ||
"build-wasm": "tree-sitter build-wasm", | ||
"lint": "eslint grammar.js", | ||
"test": "tree-sitter test && tree-sitter parse examples/* --quiet --time", | ||
"test-windows": "tree-sitter test" | ||
"parse": "tree-sitter parse", | ||
"test": "tree-sitter test" | ||
}, | ||
@@ -44,4 +68,4 @@ "tree-sitter": [ | ||
"highlights": [ | ||
"queries/highlights.scm", | ||
"node_modules/tree-sitter-c/queries/highlights.scm" | ||
"node_modules/tree-sitter-c/queries/highlights.scm", | ||
"queries/highlights.scm" | ||
], | ||
@@ -51,3 +75,45 @@ "injections": "queries/injections.scm", | ||
} | ||
] | ||
], | ||
"eslintConfig": { | ||
"env": { | ||
"commonjs": true, | ||
"es2021": true | ||
}, | ||
"extends": "google", | ||
"parserOptions": { | ||
"ecmaVersion": "latest", | ||
"sourceType": "module" | ||
}, | ||
"rules": { | ||
"arrow-parens": "off", | ||
"camel-case": "off", | ||
"indent": [ | ||
"error", | ||
2, | ||
{ | ||
"SwitchCase": 1 | ||
} | ||
], | ||
"max-len": [ | ||
"error", | ||
{ | ||
"code": 160, | ||
"ignoreComments": true, | ||
"ignoreUrls": true, | ||
"ignoreStrings": true | ||
} | ||
], | ||
"spaced-comment": [ | ||
"warn", | ||
"always", | ||
{ | ||
"line": { | ||
"markers": [ | ||
"/" | ||
] | ||
} | ||
} | ||
] | ||
} | ||
} | ||
} |
@@ -8,2 +8,3 @@ # tree-sitter-cpp | ||
[![npm][npm]](https://www.npmjs.com/package/tree-sitter-cpp) | ||
[![pypi][pypi]](https://pypi.org/project/tree-sitter-cpp) | ||
@@ -22,1 +23,2 @@ C++ grammar for [tree-sitter](https://github.com/tree-sitter/tree-sitter). | ||
[crates]: https://img.shields.io/crates/v/tree-sitter-cpp?logo=rust | ||
[pypi]: https://img.shields.io/pypi/v/tree-sitter-cpp?logo=pypi&logoColor=ffd242 |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Native code
Supply chain riskContains native code (e.g., compiled binaries or shared libraries). Including native code can obscure malicious behavior.
Found 1 instance in 1 package
No repository
Supply chain riskPackage does not have a linked source code repository. Without this field, a package will have no reference to the location of the source code use to generate the package.
Found 1 instance in 1 package
43351279
25851
23
3
6
22
1
4
+ Addednode-addon-api@^8.0.0
+ Addednode-gyp-build@^4.8.0
+ Addednode-addon-api@8.3.1(transitive)
+ Addednode-gyp-build@4.8.4(transitive)
+ Addedtree-sitter@0.21.1(transitive)
- Removednan@^2.18.0
- Removednan@2.22.2(transitive)