### Did you check existing issues? - [ ] I have read all the [tree-sitter docs](https://tree-sitter.github.io/tree-sitter/using-parsers) if it relates to using the parser - [X] I have searched the existing issues of tree-sitter-rust ### Tree-Sitter CLI Version, if relevant (output of `tree-sitter --version`) _No response_ ### Describe the bug The latest release (0.23) broke the parsing of doc-comments. Here's an example of how it looks like right now:  It should look like the following (as in release 0.21.2):  I don't know the specific commit that broke this. However, the issue is present from commit `7de6a3bc1ba213424c137f134d2872975b3b7fbe` forwards. I'm using neovim (v0.10.0) with `nvim-treesitter` plugin. Here's the tree of the wrongly parsed part: ```scheme (source_file ; [0, 0] - [7, 0] (line_comment ; [0, 0] - [1, 0] outer: (outer_doc_comment_marker) ; [0, 2] - [0, 3] doc: (doc_comment)) ; [0, 3] - [1, 0] (function_item ; [1, 0] - [3, 1] name: (identifier) ; [1, 3] - [1, 7] parameters: (parameters) ; [1, 7] - [1, 9] body: (block ; [1, 10] - [3, 1] (line_comment ; [2, 4] - [3, 0] inner: (inner_doc_comment_marker) ; [2, 6] - [2, 7] doc: (doc_comment))))) ; [2, 7] - [3, 0] ``` ### Steps To Reproduce/Bad Parse Tree 1. Open a Rust file. 2. Find (or create) a doc comment 3. The `///` and `//!` symbols of doc comments are parsed wrong, with third character parsed as operator (I think?) ### Expected Behavior/Parse Tree The `///` symbol should be parsed as one symbol. ### Repro ```Rust /// This is a doc comment fn main() { //! this is inside function comment } ```
Activity
mawkler commentedon Sep 9, 2024
Came here since I'm having the same issue
amaanq commentedon Sep 9, 2024
Highlights are implementation-dependent and are not controlled here. The parse tree is correct, this is the parser repo.
nfejzic commentedon Sep 10, 2024
@amaanq Thank you for the info 🙏🏻