tree-sitter / tree-sitter-rust

Rust grammar for tree-sitter

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Inconsistent syntax highlighting for function arguments

flobsh opened this issue · comments

Hi,

There is an inconsistency in function arguments syntax highlighting. In the code below, I would expect f in the write! macro to have the same formatting as the f in the function arguments. I am using Helix 23.05 but this seemed to be a tree-sitter-related issue.

image

Not a tree-sitter issue, you're looking for semantic tokens support

Oh okay, so that's rather an editor issue (Helix in this case)?

well, in a sense yes, but really i'd think it's the lsp (rust analyzer), I'm assuming helix properly highlights parameter semantic tokens