-
Notifications
You must be signed in to change notification settings - Fork 13.6k
Description
There doesn't seem to be keyword or comment highlighting for the first snippet on rustdoc pages.
https://doc.rust-lang.org/std/path/struct.PathBuf.html
https://doc.rust-lang.org/std/default/trait.Default.html (there is some highlighting here, but less than other snippets)
By contrast, other snippets seem to be fine, e.g. https://doc.rust-lang.org/std/vec/struct.Vec.html#examples has keyword and comment highlighting:
I searched for rustdoc syntax highlighting issues, but I couldn't find anything relevant. #75981 notes that rustdoc is using the lexer to highlight, but I'd expect that to handle at least comments correctly. This issue seems to have existed for a while, e.g. #103050 shows the same missing comment highlighting.