Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: highlight extern crate in doc comments #19137

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

asuto15
Copy link

@asuto15 asuto15 commented Feb 11, 2025

I'm new to this project and still getting familiar with the codebase.
I've added a branch to ensure that extern crate Krate; is highlighted as a module in highlight_name_ref_by_syntax, and I've updated the corresponding doctest expectations accordingly. If I've misunderstood the intended behavior or made any mistakes in these changes, please let me know. I'm happy to adjust the patch as needed.

Fixes #19041.

@rustbot rustbot added the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. label Feb 11, 2025
Copy link
Member

@lnicola lnicola left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm was sure I tried this and it made no difference. Thanks!

@lnicola
Copy link
Member

lnicola commented Feb 11, 2025

Hm, in Rust code we mark these as namespaces with crateRoot and library modifiers, we should probably match that. You can use the "Inspect Editor Tokens and Scopes" command to check.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
S-waiting-on-review Status: Awaiting review from the assignee but also interested parties.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Import aliases (crates) in doc comment injection retain their unresolvedReference
3 participants