zhangwwpeng
7930b5f983
fix(verilog): update queries ( #7400 )
...
1. Add "string" as a keyword
2. Fix issue where non-type.builtin fields are captured when using (data_type) as type.builtin
3. Add generate label
2024-11-24 10:44:23 +01:00
Fredrik Ekre
3f377c0739
fix(julia): treat :: as operator in type contexts
...
This patch captures `::` as `@operator` within
`(unary_typed_expression)` and `(typed_expression)`. These should be the
only two cases that the parser can emit when encountering `::` in the
source, but as a fallback it is still captured as `@punctuation` in all
other cases.
The reasons for capturing `::` as an operator are i) the close relation
with the other type-operators `<:` and `>:` and ii) the fact that it is
treated as an operator by the Julia parser, just like `<:` and `>:`.
2024-11-23 11:10:05 +01:00
net-solution
94853ae932
fix(astro): highlight self-closing component tags
2024-11-23 10:43:46 +01:00
Fredrik Ekre
e05c280659
fix(julia): misc fixes to type highlighting
...
This patch fixes two issues related to `@type` capturing (split out from
https://github.com/nvim-treesitter/nvim-treesitter/pull/7392 ):
- Capture the RHS of `<:` and `>:` as `@type` in `(unary_expression)`s
similarly to what is already done for `(binary_expression)`s with
these operators.
- Capture children of `(curly_expression)`s inside of
`(where_expression)`s as `@type` similarly how they are handled in
`(parametrized_type_expression)`.
2024-11-23 10:40:13 +01:00
Fredrik Ekre
28a5dc06a8
fix(julia): fix macro identifier highlight query
...
This fixes the macro identifier highlight query after the breaking
changes in https://github.com/tree-sitter/tree-sitter-julia/pull/153 .
See also
https://github.com/tree-sitter/tree-sitter-julia/pull/158/commits/9f2fb3b9a8c73ef0d2ec005c97f91274b492d48d .
2024-11-22 23:48:19 +01:00
Tomas Sandven
731fbe9ac3
feat(robot): highlight query improvements
...
- Highlight "ELSE" in inline_if_statement
- Use @string.documentation for "Documentation" settings
- Add `@spell` capture to "Documentation" settings
2024-11-22 23:19:26 +01:00
Fredrik Ekre
fcd2a5fea9
fix(julia): capture docstrings in more cases
...
This patch enables `@string.documentation` capturing, and markdown
injection, for strings attached to `(call_expression)` and
`(identifier)` nodes. For example
```julia
"docs"
foo(::Int, ::Float64)
"docs"
bar
```
2024-11-22 14:07:51 +01:00
Fredrik Ekre
2d816bb49e
fix(julia): fix injection queries
...
This patch fixes the julia `(string_literal)` injection queries after
the breaking changes in
https://github.com/tree-sitter/tree-sitter-julia/pull/153 . The queries
are simplified by the fact that string content is now directly available
as a separate `(content)` child node.
2024-11-22 13:33:54 +01:00
Riley Bruins
2d5c122af9
feat(http): more comprehensive highlights
2024-11-22 08:56:14 +01:00
Riley Bruins
1249b4cfce
fix(jsdoc): only highlight slashes in paths ( #7387 )
...
Otherwise the final slash in a doc comment `*/` will also be
highlighted.
2024-11-21 17:00:11 -08:00
Omar Valdez
8a74ac9aea
feat(python): highlight modules
2024-11-21 16:48:16 +01:00
Omar Valdez
fb12c7f8a3
feat(bash): highlight redirections
2024-11-21 16:47:55 +01:00
Omar Valdez
cd2acc803b
feat(vim): highlight prepend operator
2024-11-21 09:02:13 +01:00
nvim-treesitter-bot[bot]
c50981479e
bot(lockfile): update desktop, editorconfig, just, nu, v, xresources
2024-11-19 07:58:31 +00:00
PrestonKnopp
37427012d1
feat(gdscript): add new export annotations
2024-11-18 08:26:49 +01:00
Yi Ming
13c7caf8a6
fix(zig): begin indent at struct_declaration
2024-11-15 10:09:16 +01:00
zetashift
e1e3108cd2
feat(unison): inject markdown for doc blocks
2024-11-13 09:09:53 +01:00
zetashift
88ed26a7e6
feat(unison): add fold queries
2024-11-13 09:09:53 +01:00
zetashift
c5be87ad3e
refactor(unison): update to latest treesitter grammar
2024-11-13 09:09:53 +01:00
Christian Clason
d105f2cb7b
feat(julia): update parser and queries
2024-11-11 08:40:34 +01:00
Riley Bruins
eab2005cb5
fix(regex): more accurate highlights for named backreferences
...
Highlight both surrounding angle brackets, and only apply the operator
highlight to the actual \k operator.
2024-11-07 22:06:35 +01:00
ganhaque
ea3a37a975
fix(wgsl): indent call expression params ( #7309 )
2024-11-06 10:09:14 -08:00
David Lysenko
7c5a4632c4
feat(runescript): add parser and queries ( #7305 )
2024-11-06 17:09:38 +00:00
Riley Bruins
0d3426a2e8
fix(wgsl): indent first parameter of function definition
2024-11-06 09:24:39 +01:00
Abhishek Singh
604aa5a7c8
feat(nu): add parser and queries ( #7267 )
2024-11-05 15:25:42 +01:00
Riley Bruins
8fadb18430
feat: sway programming language
2024-11-04 08:36:41 +01:00
Riley Bruins
01a92da438
fix(rust): highlight parameters with ref in definition
2024-11-03 11:46:40 +01:00
Riley Bruins
98b46a647e
feat(regex): highlights for lazy quantifiers, \k
...
Highlights the "?" following .* and the \k backreference operator in a
pattern like the following: title=(?<quote>["'])(.*?)\k<quote>
2024-11-03 11:35:27 +01:00
Shengyu Zhang
b065b59196
fix(rst): capture (adornment) node as @markup.heading ( #7302 )
...
Node alias "adornment" is used as title's overline and underline:
5120f6e592/grammar.js (L112)
2024-11-01 09:51:17 +01:00
Elliot Fontaine
92d2501d69
feat(cylc): add parser and queries ( #7225 )
2024-10-31 17:56:58 +01:00
Riley Bruins
f26b5fb2ed
feat(thrift): small improvements
...
Less capture duplication by separating queries, include folds, move
`@variable.member` to `@property`
2024-10-30 08:39:10 +01:00
Omar Valdez
0e65a9f272
feat(bash): highlight more builtin commands
...
Commands:
- `.`
- `:`
- `true`
- `false`
2024-10-30 08:38:06 +01:00
Riley Bruins
00d2190683
fix(rust): regex injections, highlights
...
**Problem:** Rust's regex injections were not applied since the string
content is behind a `(string_content)` node, and the injections were
applied to the parent node without the `include-children` directive.
**Solution:** Apply the injections to the string content. Also highlight
them accordingly.
2024-10-27 11:51:33 +01:00
Riley Bruins
674100c1fc
fix(formatter): simplify code, remove odd line break
2024-10-26 10:07:30 +02:00
Omar Valdez
0a9108a7e4
feat(desktop): desktop parser and queries ( #7282 )
2024-10-26 10:06:22 +02:00
Omar Valdez
48fc5d1dfe
feat(bash): highlight special shell variables
2024-10-25 17:16:00 +03:00
Riley Bruins
649f6a1636
fix(rust): separate import folds from others ( #7279 )
2024-10-24 05:16:55 +00:00
ObserverOfTime
a5c7a3f6b4
fix(xml,dtd): adapt to parser changes
2024-10-22 08:56:17 +02:00
Omar Valdez
18cf02f5ef
feat(c): use @constant.macro for macro identifiers ( #7266 )
2024-10-20 10:53:45 -07:00
Omar Valdez
3ba21f96a4
feat(xresources): add parser and queries ( #7260 )
2024-10-20 10:10:30 +02:00
Amaan Qureshi
ed438691df
fix(xml): remove unused rules
2024-10-16 08:35:54 +02:00
Amaan Qureshi
8944dc64ef
fix(tlaplus): remove unused rules
2024-10-16 08:35:54 +02:00
Amaan Qureshi
6115c3664c
fix(starlark): remove unused rules
2024-10-16 08:35:54 +02:00
Amaan Qureshi
d912ede290
fix(sql): remove unused rules
2024-10-16 08:35:54 +02:00
Amaan Qureshi
07d4f138cb
fix(soql): remove unused rule
2024-10-16 08:35:54 +02:00
Amaan Qureshi
584d96b46b
fix(scala): remove unused rule
2024-10-16 08:35:54 +02:00
Amaan Qureshi
37163336e2
fix(re2c): remove unused rule
2024-10-16 08:35:54 +02:00
Amaan Qureshi
6940055133
fix(prql): remove unused rules
2024-10-16 08:35:54 +02:00
Amaan Qureshi
439fedf446
fix(ocaml_interface): remove unused rule
2024-10-16 08:35:54 +02:00
Amaan Qureshi
1a506b6007
fix(nqc): remove unused rule
2024-10-16 08:35:54 +02:00