From 77fbf5f3ad6c5654dff6f3dc2ee30500abb6b259 Mon Sep 17 00:00:00 2001 From: RubixDev Date: Fri, 28 Feb 2025 16:00:44 +0100 Subject: [PATCH] chore!: parser updates again --- queries/ecma/highlights.scm | 17 +++++++++ queries/java/injections.scm | 16 +++++++++ queries/php_only/highlights.scm | 52 ++++++++++++++++++++++++---- queries/rush/locals.scm | 12 +++---- queries/rust/locals.scm | 5 --- queries/typescript/highlights.scm | 4 +++ queries/yaml/highlights.scm | 26 ++++++++++++++ syntastica-macros/languages.toml | 20 ++++++----- syntastica-macros/src/lib.rs | 5 +-- syntastica-parsers-git/README.md | 14 ++++---- syntastica-parsers-gitdep/Cargo.toml | 19 ++++++---- syntastica-parsers-gitdep/README.md | 14 ++++---- syntastica-parsers/Cargo.toml | 6 +++- syntastica-parsers/README.md | 2 +- xtask/src/codegen.rs | 2 +- 15 files changed, 162 insertions(+), 52 deletions(-) diff --git a/queries/ecma/highlights.scm b/queries/ecma/highlights.scm index dfece9c73..8d673f048 100644 --- a/queries/ecma/highlights.scm +++ b/queries/ecma/highlights.scm @@ -178,6 +178,23 @@ ) ) +(call_expression + function: (await_expression + (identifier) @function.call + ) +) + +(call_expression + function: (await_expression + (member_expression + property: [ + (property_identifier) + (private_property_identifier) + ] @function.method.call + ) + ) +) + ; Builtins ;--------- ( diff --git a/queries/java/injections.scm b/queries/java/injections.scm index 6ea3599da..e87e41fd2 100644 --- a/queries/java/injections.scm +++ b/queries/java/injections.scm @@ -14,6 +14,22 @@ (#set! injection.language "doxygen") ) +; markdown-style javadocs: https://openjdk.org/jeps/467 +( + (line_comment) @injection.content + (#lua-match? @injection.content "^///%s") + (#offset! @injection.content 0 4 0 0) + (#set! injection.language "markdown_inline") +) + +; markdown-style javadocs: https://openjdk.org/jeps/467 +( + (line_comment) @injection.content + (#lua-match? @injection.content "^///%s+[@]") + (#offset! @injection.content 0 4 0 0) + (#set! injection.language "doxygen") +) + ( (method_invocation name: (identifier) @_method diff --git a/queries/php_only/highlights.scm b/queries/php_only/highlights.scm index d2e769395..65cd9134b 100644 --- a/queries/php_only/highlights.scm +++ b/queries/php_only/highlights.scm @@ -205,6 +205,10 @@ (qualified_name (name) @type ) + ; crates.io skip + (relative_name + (name) @type + ) ] ) @@ -223,6 +227,10 @@ (qualified_name (name) @type ) + ; crates.io skip + (relative_name + (name) @type + ) ] ) @@ -306,6 +314,10 @@ (qualified_name (name) @type ) + ; crates.io skip + (relative_name + (name) @type + ) ] ) @@ -315,6 +327,10 @@ (qualified_name (name) @type ) + ; crates.io skip + (relative_name + (name) @type + ) ] ) @@ -325,6 +341,10 @@ (qualified_name (name) @type ) + ; crates.io skip + (relative_name + (name) @type + ) ] (name) @constant ) @@ -335,6 +355,10 @@ (qualified_name (name) @type ) + ; crates.io skip + (relative_name + (name) @type + ) ] ) @@ -358,6 +382,10 @@ (qualified_name (name) @type ) + ; crates.io skip + (relative_name + (name) @type + ) ] ) @@ -380,13 +408,16 @@ ) (function_call_expression - function: (qualified_name + function: [ (name) @function.call - ) -) - -(function_call_expression - (name) @function.call + (qualified_name + (name) @function.call + ) + ; crates.io skip + (relative_name + (name) @function.call + ) + ] ) (scoped_call_expression @@ -432,6 +463,10 @@ (qualified_name (name) @constructor ) + ; crates.io skip + (relative_name + (name) @constructor + ) ] ) @@ -493,6 +528,11 @@ (name) @module ) +; crates.io skip +(relative_name + "namespace" @module.builtin +) + ; Attributes (attribute_list) @attribute diff --git a/queries/rush/locals.scm b/queries/rush/locals.scm index 57fe8d2db..16d5913d5 100644 --- a/queries/rush/locals.scm +++ b/queries/rush/locals.scm @@ -1,24 +1,24 @@ ;; Forked from https://github.com/rush-rs/tree-sitter-rush/blob/main/queries/rush/locals.scm ;; Licensed under the MIT license -(block) @scope +(block) @local.scope ; Functions (function_definition - name: (ident) @definition.function + name: (ident) @local.definition.function ) (parameter - name: (ident) @definition.parameter + name: (ident) @local.definition.parameter ) ; Variables (let_stmt - name: (ident) @definition.var + name: (ident) @local.definition.var ) (for_stmt - name: (ident) @definition.var + name: (ident) @local.definition.var ) ; References -(ident) @reference +(ident) @local.reference diff --git a/queries/rust/locals.scm b/queries/rust/locals.scm index 9f79f5643..f9928d348 100644 --- a/queries/rust/locals.scm +++ b/queries/rust/locals.scm @@ -76,11 +76,6 @@ name: (type_identifier) @local.definition.type ) -(constrained_type_parameter - left: (type_identifier) @local.definition.type -) - -; the P in remove_file>(path: P) (enum_item name: (type_identifier) @local.definition.type ) diff --git a/queries/typescript/highlights.scm b/queries/typescript/highlights.scm index 5baab0b0a..337122160 100644 --- a/queries/typescript/highlights.scm +++ b/queries/typescript/highlights.scm @@ -242,6 +242,10 @@ name: (_) @function.method ) +(abstract_method_signature + name: (property_identifier) @function.method +) + ; property signatures (property_signature name: (property_identifier) @function.method diff --git a/queries/yaml/highlights.scm b/queries/yaml/highlights.scm index bcf80ab60..25542031c 100644 --- a/queries/yaml/highlights.scm +++ b/queries/yaml/highlights.scm @@ -96,3 +96,29 @@ "---" "..." ] @punctuation.special + +; help deal with for yaml's norway problem https://www.bram.us/2022/01/11/yaml-the-norway-problem/ +; only using `true` and `false`, since Treesitter parser targets YAML spec 1.2 https://github.com/nvim-treesitter/nvim-treesitter/pull/7512#issuecomment-2565397302 +(block_mapping_pair + value: (block_node + (block_sequence + (block_sequence_item + (flow_node + (plain_scalar + (string_scalar) @boolean + (#any-of? @boolean "TRUE" "FALSE" "True" "False") + ) + ) + ) + ) + ) +) + +(block_mapping_pair + value: (flow_node + (plain_scalar + (string_scalar) @boolean + (#any-of? @boolean "TRUE" "FALSE" "True" "False") + ) + ) +) diff --git a/syntastica-macros/languages.toml b/syntastica-macros/languages.toml index fde2770ac..a8812d97c 100644 --- a/syntastica-macros/languages.toml +++ b/syntastica-macros/languages.toml @@ -35,7 +35,7 @@ name = "c" group = "some" file-types = ["c"] [languages.parser] -git = { url = "https://github.com/tree-sitter/tree-sitter-c", rev = "cf36b0354a2d75a42f87191cbd3166ad8af348e4" } +git = { url = "https://github.com/tree-sitter/tree-sitter-c", rev = "2a265d69a4caf57108a73ad2ed1e6922dd2f998c" } external-scanner = { c = false, cpp = false } ffi-func = "tree_sitter_c" rust-const = "LANGUAGE" @@ -51,7 +51,7 @@ name = "c_sharp" group = "most" file-types = ["csharp"] [languages.parser] -git = { url = "https://github.com/tree-sitter/tree-sitter-c-sharp", rev = "b27b091bfdc5f16d0ef76421ea5609c82a57dff0" } +git = { url = "https://github.com/tree-sitter/tree-sitter-c-sharp", rev = "b5eb5742f6a7e9438bee22ce8026d6b927be2cd7" } external-scanner = { c = true, cpp = false } ffi-func = "tree_sitter_c_sharp" rust-const = "LANGUAGE" @@ -356,7 +356,7 @@ name = "julia" group = "all" file-types = ["julia"] [languages.parser] -git = { url = "https://github.com/tree-sitter/tree-sitter-julia", rev = "3f9870ca1f419e480f39fc181fcfb6dad480969a" } +git = { url = "https://github.com/tree-sitter/tree-sitter-julia", rev = "12a3aede757bc7fbdfb1909507c7a6fddd31df37" } external-scanner = { c = true, cpp = false } ffi-func = "tree_sitter_julia" rust-const = "LANGUAGE" @@ -377,6 +377,7 @@ external-scanner = { c = true, cpp = false } ffi-func = "tree_sitter_latex" # rust-const = "LANGUAGE" package = "tree-sitter-latex" +# there is a package called "tree-sitter-latex" on crates.io, but that is a different latex parser # crates-io = "" generate = true [languages.queries] @@ -486,7 +487,7 @@ name = "php" group = "most" file-types = ["php"] [languages.parser] -git = { url = "https://github.com/tree-sitter/tree-sitter-php", rev = "f3a19ab3217a6e838870fc7142fa492d1fd7a7c9", path = "php" } +git = { url = "https://github.com/tree-sitter/tree-sitter-php", rev = "f7cf7348737d8cff1b13407a0bfedce02ee7b046", path = "php" } external-scanner = { c = true, cpp = false } ffi-func = "tree_sitter_php" rust-const = "LANGUAGE_PHP" @@ -566,12 +567,12 @@ name = "rush" group = "all" file-types = ["rush"] [languages.parser] -git = { url = "https://github.com/rush-rs/tree-sitter-rush", rev = "20c04a0824dabcbf8119a84979cfb1c6f6c2155f" } +git = { url = "https://github.com/rush-rs/tree-sitter-rush", rev = "babbc5c116ce964e89bc9ccc9df36d16c623fba9" } external-scanner = { c = false, cpp = false } ffi-func = "tree_sitter_rush" -# rust-const = "LANGUAGE" +rust-const = "LANGUAGE" package = "tree-sitter-rush" -# crates-io = "0.1.0" +crates-io = "0.2.0" [languages.queries] nvim-like = true injections = false @@ -582,7 +583,7 @@ name = "rust" group = "some" file-types = ["rust"] [languages.parser] -git = { url = "https://github.com/tree-sitter/tree-sitter-rust", rev = "2eaf126458a4d6a69401089b6ba78c5e5d6c1ced" } +git = { url = "https://github.com/tree-sitter/tree-sitter-rust", rev = "6e883a2adea9414799300699e78c0d2f032b5c46" } external-scanner = { c = true, cpp = false } ffi-func = "tree_sitter_rust" rust-const = "LANGUAGE" @@ -694,11 +695,12 @@ name = "verilog" group = "all" file-types = ["verilog"] [languages.parser] -git = { url = "https://github.com/gmlarumbe/tree-sitter-systemverilog", rev = "15fbf73dafaffc89050d247857beb27500ea30e8" } +git = { url = "https://github.com/gmlarumbe/tree-sitter-systemverilog", rev = "3251f8cee388314ed425c5e5da2021113f0b6afb" } external-scanner = { c = false, cpp = false } ffi-func = "tree_sitter_verilog" rust-const = "LANGUAGE" package = "tree-sitter-verilog" +# there is a package called "tree-sitter-verilog" on crates.io, but that is a different verilog parser # crates-io = "" [languages.queries] nvim-like = true diff --git a/syntastica-macros/src/lib.rs b/syntastica-macros/src/lib.rs index ad7457870..8c8e8a715 100644 --- a/syntastica-macros/src/lib.rs +++ b/syntastica-macros/src/lib.rs @@ -131,7 +131,7 @@ fn parsers_rust(crate_name: &str, crates_io: bool, query_suffix: &str) -> TokenS let name = format_ident!("{}", lang.name); let name_str = &lang.name; let (doc, body) = match &lang.parser.rust_const { - Some(ident) if (!crates_io && !lang.parser.generate) || lang.parser.crates_io.is_some() => { + Some(ident) if (!crates_io && !lang.parser.generate) || (crates_io && lang.parser.crates_io.is_some()) => { let ident = format_ident!("{ident}"); let package = format_ident!("{}", lang.parser.package.replace('-', "_")); ( @@ -161,7 +161,8 @@ fn parsers_rust(crate_name: &str, crates_io: bool, query_suffix: &str) -> TokenS functions, |lang| { lang.parser.rust_const.is_some() - && ((!crates_io && !lang.parser.generate) || lang.parser.crates_io.is_some()) + && ((!crates_io && !lang.parser.generate) + || (crates_io && lang.parser.crates_io.is_some())) }, None, query_suffix, diff --git a/syntastica-parsers-git/README.md b/syntastica-parsers-git/README.md index 78c2d380d..e961cc6d0 100644 --- a/syntastica-parsers-git/README.md +++ b/syntastica-parsers-git/README.md @@ -49,7 +49,7 @@ specifically, you don't have to worry about this. List of parsers included in the some feature - [bash](https://github.com/tree-sitter/tree-sitter-bash/tree/0c46d792d54c536be5ff7eb18eb95c70fccdb232) -- [c](https://github.com/tree-sitter/tree-sitter-c/tree/cf36b0354a2d75a42f87191cbd3166ad8af348e4) +- [c](https://github.com/tree-sitter/tree-sitter-c/tree/2a265d69a4caf57108a73ad2ed1e6922dd2f998c) - [cpp](https://github.com/tree-sitter/tree-sitter-cpp/tree/e5cea0ec884c5c3d2d1e41a741a66ce13da4d945) - [css](https://github.com/tree-sitter/tree-sitter-css/tree/6e327db434fec0ee90f006697782e43ec855adf5) - [go](https://github.com/tree-sitter/tree-sitter-go/tree/5e73f476efafe5c768eda19bbe877f188ded6144) @@ -59,7 +59,7 @@ specifically, you don't have to worry about this. - [json](https://github.com/tree-sitter/tree-sitter-json/tree/46aa487b3ade14b7b05ef92507fdaa3915a662a3) - [lua](https://github.com/muniftanjim/tree-sitter-lua/tree/68d29aa745b68ae22cbbdb5dcb68c20232521ff6) - [python](https://github.com/tree-sitter/tree-sitter-python/tree/710796b8b877a970297106e5bbc8e2afa47f86ec) -- [rust](https://github.com/tree-sitter/tree-sitter-rust/tree/2eaf126458a4d6a69401089b6ba78c5e5d6c1ced) +- [rust](https://github.com/tree-sitter/tree-sitter-rust/tree/6e883a2adea9414799300699e78c0d2f032b5c46) - [toml](https://github.com/Mathspy/tree-sitter-toml/tree/ae4cdb5d27bf876a432b6c30b6a88f56c9b3e761) - [tsx](https://github.com/tree-sitter/tree-sitter-typescript/tree/75b3874edb2dc714fb1fd77a32013d0f8699989f) - [typescript](https://github.com/tree-sitter/tree-sitter-typescript/tree/75b3874edb2dc714fb1fd77a32013d0f8699989f) @@ -71,7 +71,7 @@ specifically, you don't have to worry about this. List of parsers additionally included in the most feature - [asm](https://github.com/rush-rs/tree-sitter-asm/tree/5bb5b03e3c1ce5853b5282b9fba060f7c7bbf11e) -- [c_sharp](https://github.com/tree-sitter/tree-sitter-c-sharp/tree/b27b091bfdc5f16d0ef76421ea5609c82a57dff0) +- [c_sharp](https://github.com/tree-sitter/tree-sitter-c-sharp/tree/b5eb5742f6a7e9438bee22ce8026d6b927be2cd7) - [comment](https://github.com/stsewd/tree-sitter-comment/tree/3555706cef8b98d3e4c7379d7260548ff03ad363) - [dart](https://github.com/UserNobody14/tree-sitter-dart/tree/e81af6ab94a728ed99c30083be72d88e6d56cf9e) - [diff](https://github.com/the-mikedavis/tree-sitter-diff/tree/e42b8def4f75633568f1aecfe01817bf15164928) @@ -81,7 +81,7 @@ specifically, you don't have to worry about this. - [jsonc](https://gitlab.com/WhyNotHugo/tree-sitter-jsonc/tree/02b01653c8a1c198ae7287d566efa86a135b30d5) - [markdown](https://github.com/MDeiml/tree-sitter-markdown/tree/192407ab5a24bfc24f13332979b5e7967518754a) - [markdown_inline](https://github.com/MDeiml/tree-sitter-markdown/tree/192407ab5a24bfc24f13332979b5e7967518754a) -- [php](https://github.com/tree-sitter/tree-sitter-php/tree/f3a19ab3217a6e838870fc7142fa492d1fd7a7c9) +- [php](https://github.com/tree-sitter/tree-sitter-php/tree/f7cf7348737d8cff1b13407a0bfedce02ee7b046) - [regex](https://github.com/tree-sitter/tree-sitter-regex/tree/b638d29335ef41215b86732dd51be34c701ef683) - [ruby](https://github.com/tree-sitter/tree-sitter-ruby/tree/89bd7a8e5450cb6a942418a619d30469f259e5d6) - [scala](https://github.com/tree-sitter/tree-sitter-scala/tree/d67fe3ba3879bd7ba74bd7f56c9a38fed241ba25) @@ -96,15 +96,15 @@ specifically, you don't have to worry about this. - [ejs](https://github.com/tree-sitter/tree-sitter-embedded-template/tree/8495d106154741e6d35d37064f864758ece75de6) - [erb](https://github.com/tree-sitter/tree-sitter-embedded-template/tree/8495d106154741e6d35d37064f864758ece75de6) - [hexdump](https://github.com/rush-rs/tree-sitter-hexdump/tree/09eaf4fcfed00be93928d7d3d82b490cd1343b80) -- [julia](https://github.com/tree-sitter/tree-sitter-julia/tree/3f9870ca1f419e480f39fc181fcfb6dad480969a) +- [julia](https://github.com/tree-sitter/tree-sitter-julia/tree/12a3aede757bc7fbdfb1909507c7a6fddd31df37) - [latex](https://github.com/latex-lsp/tree-sitter-latex/tree/7b06f6ed394308e7407a1703d2724128c45fc9d7) - [llvm](https://github.com/benwilliamgraham/tree-sitter-llvm/tree/c14cb839003348692158b845db9edda201374548) - [ocaml](https://github.com/tree-sitter/tree-sitter-ocaml/tree/91e4d9106f5da8199ab5158ba65e02da3e664597) - [ocaml_interface](https://github.com/tree-sitter/tree-sitter-ocaml/tree/91e4d9106f5da8199ab5158ba65e02da3e664597) - [ql](https://github.com/tree-sitter/tree-sitter-ql/tree/1fd627a4e8bff8c24c11987474bd33112bead857) -- [rush](https://github.com/rush-rs/tree-sitter-rush/tree/20c04a0824dabcbf8119a84979cfb1c6f6c2155f) +- [rush](https://github.com/rush-rs/tree-sitter-rush/tree/babbc5c116ce964e89bc9ccc9df36d16c623fba9) - [ursa](https://github.com/ursalang/tree-sitter-ursa/tree/d023d044590d461bf586c56854b2630fef0d17cc) -- [verilog](https://github.com/gmlarumbe/tree-sitter-systemverilog/tree/15fbf73dafaffc89050d247857beb27500ea30e8) +- [verilog](https://github.com/gmlarumbe/tree-sitter-systemverilog/tree/3251f8cee388314ed425c5e5da2021113f0b6afb) - [wat](https://github.com/wasm-lsp/tree-sitter-wasm/tree/2ca28a9f9d709847bf7a3de0942a84e912f59088) diff --git a/syntastica-parsers-gitdep/Cargo.toml b/syntastica-parsers-gitdep/Cargo.toml index bafd1ff1a..d3f2a8061 100644 --- a/syntastica-parsers-gitdep/Cargo.toml +++ b/syntastica-parsers-gitdep/Cargo.toml @@ -146,7 +146,7 @@ python = ["dep:tree-sitter-python"] ql = ["dep:tree-sitter-ql"] regex = ["dep:tree-sitter-regex"] ruby = ["dep:tree-sitter-ruby"] -rush = [] +rush = ["dep:tree-sitter-rush"] rust = ["dep:tree-sitter-rust"] scala = ["dep:tree-sitter-scala"] scss = [] @@ -171,12 +171,12 @@ rev = "0c46d792d54c536be5ff7eb18eb95c70fccdb232" [dependencies.tree-sitter-c] optional = true git = "https://github.com/tree-sitter/tree-sitter-c" -rev = "cf36b0354a2d75a42f87191cbd3166ad8af348e4" +rev = "2a265d69a4caf57108a73ad2ed1e6922dd2f998c" [dependencies.tree-sitter-c-sharp] optional = true git = "https://github.com/tree-sitter/tree-sitter-c-sharp" -rev = "b27b091bfdc5f16d0ef76421ea5609c82a57dff0" +rev = "b5eb5742f6a7e9438bee22ce8026d6b927be2cd7" [dependencies.tree-sitter-cpp] optional = true @@ -236,7 +236,7 @@ rev = "46aa487b3ade14b7b05ef92507fdaa3915a662a3" [dependencies.tree-sitter-julia] optional = true git = "https://github.com/tree-sitter/tree-sitter-julia" -rev = "3f9870ca1f419e480f39fc181fcfb6dad480969a" +rev = "12a3aede757bc7fbdfb1909507c7a6fddd31df37" [dependencies.tree-sitter-lua] optional = true @@ -256,7 +256,7 @@ rev = "91e4d9106f5da8199ab5158ba65e02da3e664597" [dependencies.tree-sitter-php] optional = true git = "https://github.com/tree-sitter/tree-sitter-php" -rev = "f3a19ab3217a6e838870fc7142fa492d1fd7a7c9" +rev = "f7cf7348737d8cff1b13407a0bfedce02ee7b046" [dependencies.tree-sitter-python] optional = true @@ -278,10 +278,15 @@ optional = true git = "https://github.com/tree-sitter/tree-sitter-ruby" rev = "89bd7a8e5450cb6a942418a619d30469f259e5d6" +[dependencies.tree-sitter-rush] +optional = true +git = "https://github.com/rush-rs/tree-sitter-rush" +rev = "babbc5c116ce964e89bc9ccc9df36d16c623fba9" + [dependencies.tree-sitter-rust] optional = true git = "https://github.com/tree-sitter/tree-sitter-rust" -rev = "2eaf126458a4d6a69401089b6ba78c5e5d6c1ced" +rev = "6e883a2adea9414799300699e78c0d2f032b5c46" [dependencies.tree-sitter-scala] optional = true @@ -296,7 +301,7 @@ rev = "75b3874edb2dc714fb1fd77a32013d0f8699989f" [dependencies.tree-sitter-verilog] optional = true git = "https://github.com/gmlarumbe/tree-sitter-systemverilog" -rev = "15fbf73dafaffc89050d247857beb27500ea30e8" +rev = "3251f8cee388314ed425c5e5da2021113f0b6afb" [dependencies.tree-sitter-yaml] optional = true diff --git a/syntastica-parsers-gitdep/README.md b/syntastica-parsers-gitdep/README.md index 37e936e6d..943482d13 100644 --- a/syntastica-parsers-gitdep/README.md +++ b/syntastica-parsers-gitdep/README.md @@ -19,7 +19,7 @@ for more information on all parser collections. List of parsers included in the some feature - [bash](https://github.com/tree-sitter/tree-sitter-bash/tree/0c46d792d54c536be5ff7eb18eb95c70fccdb232) -- [c](https://github.com/tree-sitter/tree-sitter-c/tree/cf36b0354a2d75a42f87191cbd3166ad8af348e4) +- [c](https://github.com/tree-sitter/tree-sitter-c/tree/2a265d69a4caf57108a73ad2ed1e6922dd2f998c) - [cpp](https://github.com/tree-sitter/tree-sitter-cpp/tree/e5cea0ec884c5c3d2d1e41a741a66ce13da4d945) - [css](https://github.com/tree-sitter/tree-sitter-css/tree/6e327db434fec0ee90f006697782e43ec855adf5) - [go](https://github.com/tree-sitter/tree-sitter-go/tree/5e73f476efafe5c768eda19bbe877f188ded6144) @@ -29,7 +29,7 @@ for more information on all parser collections. - [json](https://github.com/tree-sitter/tree-sitter-json/tree/46aa487b3ade14b7b05ef92507fdaa3915a662a3) - [lua](https://github.com/muniftanjim/tree-sitter-lua/tree/68d29aa745b68ae22cbbdb5dcb68c20232521ff6) - [python](https://github.com/tree-sitter/tree-sitter-python/tree/710796b8b877a970297106e5bbc8e2afa47f86ec) -- [rust](https://github.com/tree-sitter/tree-sitter-rust/tree/2eaf126458a4d6a69401089b6ba78c5e5d6c1ced) +- [rust](https://github.com/tree-sitter/tree-sitter-rust/tree/6e883a2adea9414799300699e78c0d2f032b5c46) - [toml](https://github.com/Mathspy/tree-sitter-toml/tree/ae4cdb5d27bf876a432b6c30b6a88f56c9b3e761) (not supported by this collection) - [tsx](https://github.com/tree-sitter/tree-sitter-typescript/tree/75b3874edb2dc714fb1fd77a32013d0f8699989f) - [typescript](https://github.com/tree-sitter/tree-sitter-typescript/tree/75b3874edb2dc714fb1fd77a32013d0f8699989f) @@ -41,7 +41,7 @@ for more information on all parser collections. List of parsers additionally included in the most feature - [asm](https://github.com/rush-rs/tree-sitter-asm/tree/5bb5b03e3c1ce5853b5282b9fba060f7c7bbf11e) -- [c_sharp](https://github.com/tree-sitter/tree-sitter-c-sharp/tree/b27b091bfdc5f16d0ef76421ea5609c82a57dff0) +- [c_sharp](https://github.com/tree-sitter/tree-sitter-c-sharp/tree/b5eb5742f6a7e9438bee22ce8026d6b927be2cd7) - [comment](https://github.com/stsewd/tree-sitter-comment/tree/3555706cef8b98d3e4c7379d7260548ff03ad363) (not supported by this collection) - [dart](https://github.com/UserNobody14/tree-sitter-dart/tree/e81af6ab94a728ed99c30083be72d88e6d56cf9e) (not supported by this collection) - [diff](https://github.com/the-mikedavis/tree-sitter-diff/tree/e42b8def4f75633568f1aecfe01817bf15164928) @@ -51,7 +51,7 @@ for more information on all parser collections. - [jsonc](https://gitlab.com/WhyNotHugo/tree-sitter-jsonc/tree/02b01653c8a1c198ae7287d566efa86a135b30d5) (not supported by this collection) - [markdown](https://github.com/MDeiml/tree-sitter-markdown/tree/192407ab5a24bfc24f13332979b5e7967518754a) - [markdown_inline](https://github.com/MDeiml/tree-sitter-markdown/tree/192407ab5a24bfc24f13332979b5e7967518754a) -- [php](https://github.com/tree-sitter/tree-sitter-php/tree/f3a19ab3217a6e838870fc7142fa492d1fd7a7c9) +- [php](https://github.com/tree-sitter/tree-sitter-php/tree/f7cf7348737d8cff1b13407a0bfedce02ee7b046) - [regex](https://github.com/tree-sitter/tree-sitter-regex/tree/b638d29335ef41215b86732dd51be34c701ef683) - [ruby](https://github.com/tree-sitter/tree-sitter-ruby/tree/89bd7a8e5450cb6a942418a619d30469f259e5d6) - [scala](https://github.com/tree-sitter/tree-sitter-scala/tree/d67fe3ba3879bd7ba74bd7f56c9a38fed241ba25) @@ -66,15 +66,15 @@ for more information on all parser collections. - [ejs](https://github.com/tree-sitter/tree-sitter-embedded-template/tree/8495d106154741e6d35d37064f864758ece75de6) - [erb](https://github.com/tree-sitter/tree-sitter-embedded-template/tree/8495d106154741e6d35d37064f864758ece75de6) - [hexdump](https://github.com/rush-rs/tree-sitter-hexdump/tree/09eaf4fcfed00be93928d7d3d82b490cd1343b80) (not supported by this collection) -- [julia](https://github.com/tree-sitter/tree-sitter-julia/tree/3f9870ca1f419e480f39fc181fcfb6dad480969a) +- [julia](https://github.com/tree-sitter/tree-sitter-julia/tree/12a3aede757bc7fbdfb1909507c7a6fddd31df37) - [latex](https://github.com/latex-lsp/tree-sitter-latex/tree/7b06f6ed394308e7407a1703d2724128c45fc9d7) (not supported by this collection) - [llvm](https://github.com/benwilliamgraham/tree-sitter-llvm/tree/c14cb839003348692158b845db9edda201374548) (not supported by this collection) - [ocaml](https://github.com/tree-sitter/tree-sitter-ocaml/tree/91e4d9106f5da8199ab5158ba65e02da3e664597) - [ocaml_interface](https://github.com/tree-sitter/tree-sitter-ocaml/tree/91e4d9106f5da8199ab5158ba65e02da3e664597) - [ql](https://github.com/tree-sitter/tree-sitter-ql/tree/1fd627a4e8bff8c24c11987474bd33112bead857) -- [rush](https://github.com/rush-rs/tree-sitter-rush/tree/20c04a0824dabcbf8119a84979cfb1c6f6c2155f) (not supported by this collection) +- [rush](https://github.com/rush-rs/tree-sitter-rush/tree/babbc5c116ce964e89bc9ccc9df36d16c623fba9) - [ursa](https://github.com/ursalang/tree-sitter-ursa/tree/d023d044590d461bf586c56854b2630fef0d17cc) (not supported by this collection) -- [verilog](https://github.com/gmlarumbe/tree-sitter-systemverilog/tree/15fbf73dafaffc89050d247857beb27500ea30e8) +- [verilog](https://github.com/gmlarumbe/tree-sitter-systemverilog/tree/3251f8cee388314ed425c5e5da2021113f0b6afb) - [wat](https://github.com/wasm-lsp/tree-sitter-wasm/tree/2ca28a9f9d709847bf7a3de0942a84e912f59088) (not supported by this collection) diff --git a/syntastica-parsers/Cargo.toml b/syntastica-parsers/Cargo.toml index 88d517869..1429e855e 100644 --- a/syntastica-parsers/Cargo.toml +++ b/syntastica-parsers/Cargo.toml @@ -143,7 +143,7 @@ python = ["dep:tree-sitter-python"] ql = ["dep:tree-sitter-ql"] regex = ["dep:tree-sitter-regex"] ruby = ["dep:tree-sitter-ruby"] -rush = [] +rush = ["dep:tree-sitter-rush"] rust = ["dep:tree-sitter-rust"] scala = ["dep:tree-sitter-scala"] scss = [] @@ -251,6 +251,10 @@ version = "=0.24.3" optional = true version = "=0.23.1" +[dependencies.tree-sitter-rush] +optional = true +version = "=0.2.0" + [dependencies.tree-sitter-rust] optional = true version = "=0.23.2" diff --git a/syntastica-parsers/README.md b/syntastica-parsers/README.md index a2de52b10..9a6211b2b 100644 --- a/syntastica-parsers/README.md +++ b/syntastica-parsers/README.md @@ -72,7 +72,7 @@ for more information on all parser collections. - [ocaml](https://docs.rs/tree-sitter-ocaml/0.24.0/) - [ocaml_interface](https://docs.rs/tree-sitter-ocaml/0.24.0/) - [ql](https://docs.rs/tree-sitter-ql/0.23.1/) -- [rush](https://github.com/rush-rs/tree-sitter-rush) (not supported by this collection) +- [rush](https://docs.rs/tree-sitter-rush/0.2.0/) - [ursa](https://github.com/ursalang/tree-sitter-ursa) (not supported by this collection) - [verilog](https://github.com/gmlarumbe/tree-sitter-systemverilog) (not supported by this collection) - [wat](https://github.com/wasm-lsp/tree-sitter-wasm) (not supported by this collection) diff --git a/xtask/src/codegen.rs b/xtask/src/codegen.rs index ede1c5ac4..ea0b217db 100644 --- a/xtask/src/codegen.rs +++ b/xtask/src/codegen.rs @@ -181,7 +181,7 @@ fn parsers_toml_deps(toml: &mut String, git: bool) { let mut added_packages = vec![]; for lang in crate::LANGUAGE_CONFIG.languages.iter().filter(|lang| { lang.parser.rust_const.is_some() - && ((git && !lang.parser.generate) || lang.parser.crates_io.is_some()) + && ((git && !lang.parser.generate) || (!git && lang.parser.crates_io.is_some())) }) { let package = &lang.parser.package; let url = &lang.parser.git.url;