| Commit message (Collapse) | Author | Age |
|
|
|
|
| |
* rust: add highlight scope for type parameters
* handle optional type parameters
|
| |
|
|
|
|
|
| |
looks like two lines were unintentionally joined - it doesn't appear to
affect the functionality, but it's confusing to read
|
| |
|
|
|
|
|
|
|
| |
* Highlight sqlx's `query_scalar{,_unchecked}` macros as SQL
* Update injections.scm
* fixup copy-pasta
|
| |
|
|
|
|
|
|
|
| |
* Update highlights.scm
* Update highlights.scm
* Update themes.md
|
| |
|
| |
|
|
|
|
| |
Ref: https://github.com/tree-sitter/tree-sitter-rust/commit/3ddebf46e6fe5e27fa03dc07a829a766b9979c8d
|
|
|
|
|
|
|
| |
Without this scoped attribute macros are not matched as macros.
Eg
```
#[path::macro]
```
|
| |
|
|
|
|
|
|
|
|
|
|
|
| |
This stanza highlights functions within trait definitions. For example,
in:
pub trait Widget {
fn render(self, area: Rect, buf: &mut Buffer);
}
`render` is currently highlighted as a variable. With this change it's
highlighted as a function.
|
|
|
|
| |
Co-authored-by: Kirawi <67773714+kirawi@users.noreply.github.com>
Co-authored-by: Gavin Crawford <gavincrawford@users.noreply.github.com>
|
| |
|
| |
|
|
|
|
|
|
| |
There don't appear to be any regressions from the updates.
Also included is a fix which highlights the "#" as in attributes
as punctuation. This was previously unhighlighted.
|
| |
|
|
|
| |
Co-authored-by: Vince Mutolo <vince@mutolo.org>
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
| |
The fix comes from the rewriting of the `closure_parameters` stanza:
it was capturing the entire `closure_parameters` node including
paretheses, whitespace, and commas. Capturing the identifiers within
fixes the tracking.
In order to make sure locals definitions from closure parameters don't
leak out of the body of the closure, though, we should also mark the
closure itself as a locals scope.
|
|
|
|
|
|
|
|
|
| |
* add punctuation highlights for commas as in function parameters
* remove stray `variable.parameter` highlight
* I couldn't find any regressions from this and it fixes an
edge case I ran into (but sadly did not record 😓)
* highlight `fn` as `keyword.function`
* the theme docs have `fn` as an example so it seems fitting
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
|
|
| |
Closures like
iter.map(|a| a + 1)
Are sort-of functions, so `]f` or `maf` or `mif` can apply to them
as well as named function definitions.
|
| |
|
|
|
|
| |
textobjects (#2494)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* WIP: Rework indentation system
* Add ComplexNode for context-aware indentation (including a proof of concept for assignment statements in rust)
* Add switch statements to Go indents.toml (fixes the second half of issue #1523)
Remove commented-out code
* Migrate all existing indentation queries.
Add more options to ComplexNode and use them to improve C/C++ indentation.
* Add comments & replace Option<Vec<_>> with Vec<_>
* Add more detailed documentation for tree-sitter indentation
* Improve code style in indent.rs
* Use tree-sitter queries for indentation instead of TOML config.
Migrate existing indent queries.
* Add documentation for the new indent queries.
Change xtask docgen to look for indents.scm instead of indents.toml
* Improve code style in indent.rs.
Fix an issue with the rust indent query.
* Move indentation test sources to separate files.
Add `#not-kind-eq?`, `#same-line?` and `#not-same-line` custom predicates.
Improve the rust and c indent queries.
* Fix indent test.
Improve rust indent queries.
* Move indentation tests to integration test folder.
* Improve code style in indent.rs.
Reuse tree-sitter cursors for indentation queries.
* Migrate HCL indent query
* Replace custom loading in indent tests with a designated languages.toml
* Update indent query file name for --health command.
* Fix single-space formatting in indent queries.
* Add explanation for unwrapping.
Co-authored-by: Triton171 <triton0171@gmail.com>
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* add tree-sitter-regex
* adapt regex highlights from upstream
* inject regex into elixir sigil_r/2 and sigil_R/2
* generate lang-support docs
* capture interesting nodes in character-ranges
* make $.character_class captures more consistent
* fix fallthrough behavior for character classes
* capture pattern characters as 'string'
* use latest tree-sitter-regex
* set elixir regex injections as combined
* add link to upstream queries
* inject regex in rust into 'Regex::new' raw string literals
|
|
|
|
|
|
|
| |
rules (always use the indent of the current line for a new line). (#1341)
Fix several bugs in the treesitter indentation calculation.
Co-authored-by: Triton171 <triton0171@gmail.com>
|
|
|
|
|
|
| |
- Differentiates between `as` keyword as a binary type cast
operator and import renamer.
- `mod` and `use` are now under `@keyword.control.import`,
but `mod` is a `@keyword` if used as `mod name;`.
|
|
|
|
|
| |
- Highlight fragment specifiers (expr, tt, in macro
definitions) with @type.
- Highlight attributes as macros
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* Add tree-sitter-comment
Fix #1164
* fix precedence in tree-sitter-comment highlights
connects https://github.com/helix-editor/helix/pull/1170
* set injection-regex for comment language
* remove comment filetype
* fix comment injections for neovim-style injections tags
* add comment injections for elixir
* remove f.comment
* fix spacing in .gitmodules
* run 'cargo xtask docgen'
Co-authored-by: Ivan Tham <pickfire@riseup.net>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* updated theme scopes
variable.property -> variable.field
property -> variable.field
* updated theme scopes
* update book and themes
updated book and themes to reflect scope changes
* wip
* update more queries
* update dark_plus.toml
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* Add treesitter textobject queries
Only for Go, Python and Rust for now.
* Add tree-sitter textobjects
Only has functions and class objects as of now.
* Fix tests
* Add docs for tree-sitter textobjects
* Add guide for creating new textobject queries
* Add parameter textobject
Only parameter.inside is implemented now, parameter.around
will probably require custom predicates akin to nvim' `make-range`
since we want to select a trailing comma too (a comma will be
an anonymous node and matching against them doesn't work similar
to named nodes)
* Simplify TextObject cell init
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
|
|
| |
* changed some gruvbox highlights
* more stuff including cursors
* use property instead
* use variable.property
|
| |
|
|
|
|
|
| |
if/if let are already handled by block, and keeping these scopes would
indent else blocks one level too far.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* rewrote Rust highlights.scm
* wip
* wip
* wip
* wip
* fixed type highlighting
* wip
* rewrite again
* moved operators
* missing newline
* missing newline
* update book
* fix constructor highlighting
* fix constructor highlighting
* fix const highlighting
* better constructor highlighting
* remove dup, bug was my locals.scm file
* fixed docs
* merge
* fixed for highlighting
* add yield
* remove yield
* added yield back
* fixed yield highlighting
* unecessary
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* wip
* Add VSCode Dark+ Theme
wip
wip
wip
wip
wip
wip
properly detect constants
add bool
wip
* suggestion
* add variant for c/c++
* fix hexcode error
* removed regex highlight
* fixed constant higlighting
* wip
* add space
* add suggestions
* update theme
* update book
* suggestions
* fix c/c++ enum
* update book
|
| |
|
| |
|
| |
|
| |
|