tree-sitter-rust icon indicating copy to clipboard operation
tree-sitter-rust copied to clipboard

Rust grammar for tree-sitter

Results 55 tree-sitter-rust issues
Sort by recently updated
recently updated
newest added

Code extracted from rustc souce code: ```rust fn hash_body( item_like: impl for>, hir_body_nodes: &mut Vec, ) -> Fingerprint { let hash = hash(hcx, HirItemLike { item_like: &item_like }); } fn...

Not sure if it's a proper bug, but I got myself unable to classify some symbols on Atom inside macros. Like, when I define something like: ``` '"+"' : 'keyword.operator.add'...

Other tree-sitter grammars parse `->`, `&&`, `+=`, etc. as an operator. This grammar should be consistent with the standard convention.

Now that the `box` keyword has been reserved in Rust2018, and it is possible to use it behind a gate I think it would make sense to highlight it as...

In `array_expression` and `tuple_expression`, I'm pretty sure the attributes after the opening bracket should be `inner_attribute_item`, not `attribute_item`. See https://doc.rust-lang.org/reference/expressions/array-expr.html . There's a test in declarations.txt that expects the current...

As reference: 1. https://github.com/rust-lang/rust/issues/39412 2. https://github.com/rust-lang/rfcs/pull/1584 3. https://github.com/rust-lang/rfcs/blob/master/text/1584-macros.md

There seems to be a mismatch between WASM and native builds (on macOS). I built the CLI from latest tree-sitter's master (`4c0fa29`) and tried this code: ```rust macro_rules! impl_pred {}...

According to https://doc.rust-lang.org/reference/items/functions.html we could remove `default`. Its presence in the grammar leads to error with for example: ```rust pub struct A { a: default::C, } ``` And nothing in:...

⚠️ Do not merge yet ⚠️ Refs https://github.com/rust-lang/rfcs/pull/2544

[Rust 1.65 (currently in beta)](https://releases.rs/docs/unreleased/1.65.0/) will include [`let ... else` statements](https://github.com/rust-lang/rfcs/blob/master/text/3137-let-else.md). It'd be nice to have those highlighted in a way that does not cause `ERROR`s all over the place,...