aboutsummaryrefslogtreecommitdiffstats
path: root/queries/rust
Commit message (Collapse)AuthorAgeFilesLines
* fix(rust): inject regex into RegexBuilder instead of ByteRegexBuildermay2025-03-081-2/+2
|
* fix(rust): inject html and json in macro invocations (#7715)ginnyTheCat2025-03-081-10/+4
|
* bot(lockfile): update php, php_only, rust, vnvim-treesitter-bot[bot]2025-02-281-3/+0
|
* Fix panic!, assert*!, and dbg! macro queries.Kieran Siek2025-02-041-6/+6
|
* feat(rust): highlight "gen" and "raw" keywords (#7419)flippette2024-11-291-0/+2
|
* fix(rust): highlight parameters with ref in definitionRiley Bruins2024-11-031-0/+8
|
* fix(rust): regex injections, highlightsRiley Bruins2024-10-272-4/+52
| | | | | | | | | **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.
* fix(rust): separate import folds from others (#7279)Riley Bruins2024-10-241-1/+1
|
* feat(highlights): capture wildcard patterns as `@character.special` (#7153)Omar Valdez2024-09-201-4/+13
|
* fix(rust): comment marker should not be `@operator` (#7135)Amaan Qureshi2024-09-101-11/+14
|
* feat(rust): add highlight for shorthand_field_identifierTobias Schmitz2024-08-221-0/+2
|
* feat(highlights): capture wildcard imports as `@character.special`Omar Valdez2024-08-011-0/+3
|
* feat(rust): fold block expressions (#6754)Riley Bruins2024-06-101-0/+1
|
* feat(rust): underscore match arms, parametersRiley Bruins2024-05-081-2/+8
|
* feat: import statement folds for common languagesRiley Bruins2024-05-011-1/+1
|
* feat: more `@keyword.type` capturesRiley Bruins2024-05-011-5/+8
|
* fix(rust): update queries from upstreamAmaan Qureshi2024-04-071-1/+1
|
* fix(rust): indentation in multi-line tuple pattern (#6402)ganhaque2024-04-041-0/+4
| | | | | * fix(rust): indentation in multi-line tuple pattern * test(indent): rust - add test for tuple pattern indent
* fix(rust): indentation in multi-line for expressionganhaque2024-04-041-1/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | Fix indentation when the for loop expression is on multiple lines Example: previous: ```rust for ( abc, def ) in thing.iter() { // ... } ``` new: ```rust for ( abc, def ) in thing.iter() { // ... } ```
* fix(rust): indentation in tuple type patternsganhaque2024-04-041-0/+4
|
* fix(rust): indentation in tuple struct patternsAmaan Qureshi2024-03-261-0/+4
|
* refactor(format): drop extra indentation for fieldPhạm Huy Hoàng2024-03-214-113/+82
|
* feat(rust): improve indentsAmaan Qureshi2024-03-211-2/+10
|
* fix(rust): dedent on macro definition endAmaan Qureshi2024-03-201-1/+12
|
* feat(rust): move pub to `@keyword.modifier`Riley Bruins2024-03-161-4/+1
| | | | Also consolidates most of the captures
* feat(rust,lalrpop): `@attribute` for lifetimesJaehwang Jung2024-03-161-4/+8
| | | | `@keyword` is only for language-defined keywords.
* feat(highlights)!: `@keyword.storage` → `@keyword.modifier`Jaehwang Jung2024-03-161-2/+2
|
* feat(highlights)!: keyword `@type.qualifier` → `@keyword.modifier`Jaehwang Jung2024-03-161-1/+1
|
* feat(highlights)!: enforce documented captures (#6232)Christian Clason2024-03-031-1/+1
| | | | | | | | | | | | | | | Problem: Allowing undocumented "secret" (sub)captures makes it harder to write comprehensive colorschemes and catch inconsistent captures. Solution: Only allow captures listed in CONTRIBUTING.md. Add useful (cross-language) subcaptures and drop language-specific or too niche ones. Follow-up: Adding further `*.builtin` captures and changing queries to use them. Language-specific subcaptures should instead be added in user config or a custom language plugin.
* feat(rust): add more regex injection queriesAmaan Qureshi2024-02-251-2/+30
|
* feat(rust): add doc commentsChristian Clason2024-02-171-13/+4
|
* feat(slint)!: change to the official parser (#6027)Tobias Hunger2024-02-091-0/+20
| | | | | | | | | | | This change replaces the slint parser written and maintained by @jrmoulton with the official one hosted in the slint-ui organization on github. A huge thank you to @jrmoulton for all his work on the tree-sitter parser! --------- Co-authored-by: jrmoulton <jaredmoulton3@gmail.com>
* chore(rust): update highlightsAmaan Qureshi2024-01-241-0/+5
|
* fix(rust): Follow upstream injectionsPhạm Huy Hoàng2024-01-241-1/+2
| | | | | | tree-sitter-rust and helix both have `injection.include-children` for the pattern in this PR. So it's best to changed to match the intended results
* chore: format queriesPhạm Huy Hoàng2024-01-211-2/+1
|
* fix(rust): add `const_item` to foldsAmaan Qureshi2024-01-201-0/+1
|
* fix(rust): Add back 1 indent for macro rules (#5834)Pham Huy Hoang2024-01-201-0/+10
|
* chore(rust): tweak injections, add json macro injectionAmaan Qureshi2024-01-191-1/+1
|
* chore: query formattingPham Huy Hoang2024-01-195-157/+268
|
* feat!: align standard captures with upstreamChristian Clason2024-01-191-34/+34
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Problem: Sharing highlight queries with upstream tree-sitter and Helix is difficult. Solution: Where reasonable, use capture names in tree-sitter's standard list or Helix's Atom-style hierarchy. Specifically: * tree-sitter "standard capture names" (https://github.com/tree-sitter/tree-sitter/blob/3f44b896852eb7daaa6df4fb778c9bb52c70c815/highlight/src/lib.rs#L20-L72): - `@parameter` -> `@variable.parameter` - `@field` -> `@variable.member` - `@namespace` -> `@module` - `@float` -> `@number.float` - `@symbol` -> `@string.special.symbol` - `@string.regex` -> `@string.regexp` - `@text.*` -> `@markup.*` (`strong`, `italic`, `link`, `strikethrough`; with exceptions; see below) - `@text.title` -> `@markup.heading` - `@text.literal` -> `@markup.raw` - `@text.reference` -> `@markup.link` - `@text.uri` -> `@markup.link.url` (in markup links) - `@string.special` -> `@markup.link.label` (non-url links) - `@punctuation.special` -> `@markup.list` (markdown lists only; move subitems from `@text.todo`) * Helix captures (https://docs.helix-editor.com/master/themes.html#syntax-highlighting): - `@method` -> `@function.method` - `@method.call` -> `@function.method.call` - `@text.{todo,warning,note,danger}` -> `@comment.{error,warning,hint,info,todo}` - `@text.diff.{add,delete,}` -> `@diff.{plus,minus,delta}` - `@text.uri` -> `@string.special.url` (outside markup) - `@preproc` -> `@keyword.directive` - `@define` -> `@keyword.directive`(`.define`?) - `@storageclass` -> `@keyword.storage` - `@conditional` -> `@keyword.conditional` - `@debug` -> `@keyword.debug` - `@exception` -> `@keyword.exception` - `@include` -> `@keyword.import` - `@repeat` -> `@keyword.repeat` * cleanup - remove some redundant `@conceal` (but still allow it for conceal-only patterns) - remove obsolete `@error` (syntax linting is out of scope for this repo) - sort, cleanup capture list in `CONTRIBUTING.md`
* feat(locals)!: switch to upstream capturesChristian Clason2024-01-191-26/+26
|
* fix(rust): highlight inline attributes properlyRiley Bruins2023-12-181-0/+1
|
* chore(rust): update queries from upstreamAmaan Qureshi2023-11-171-1/+1
|
* fix(rust): add foreign_mod_item to foldsAmaan Qureshi2023-10-301-20/+22
|
* feat: add DoxygenAmaan Qureshi2023-08-261-1/+1
|
* feat: add re2cAmaan Qureshi2023-08-241-0/+4
|
* chore(injections)!: update injection syntax to 0.9Pham Huy Hoang2023-08-121-14/+19
| | | | | | | | | Since 0.9, @lang syntax is still available as fallback but will soon be deprecated. Because of that, new syntax should be adopted once 0.9 becomes the baseline requirements for nvim-treesitter - update health check - update doc
* lint(locals): use `#set!` to keep query linter happyChristian Clason2023-06-221-2/+2
|
* style(rust): better formattingAmaan Qureshi2023-05-091-26/+88
|
* feat(rust): distinguish enum members betterAmaan Qureshi2023-05-091-0/+12
|