-
-
Notifications
You must be signed in to change notification settings - Fork 14.7k
rustdoc: improve attribute span handling in diagnostics #150735
Copy link
Copy link
Closed
Labels
A-intra-doc-linksArea: Intra-doc links, the ability to link to items in docs by nameArea: Intra-doc links, the ability to link to items in docs by nameT-rustdocRelevant to the rustdoc team, which will review and decide on the PR/issue.Relevant to the rustdoc team, which will review and decide on the PR/issue.
Metadata
Metadata
Assignees
Labels
A-intra-doc-linksArea: Intra-doc links, the ability to link to items in docs by nameArea: Intra-doc links, the ability to link to items in docs by nameT-rustdocRelevant to the rustdoc team, which will review and decide on the PR/issue.Relevant to the rustdoc team, which will review and decide on the PR/issue.
Type
Fields
Give feedbackNo fields configured for issues without a type.
In #150721 intra-doc links are rendered for deprecation notes.
Currently the span that is used when reporting an error (e.g. the link cannot be resolved) is a bit too broad. A span containing all doc comments and the deprecated attribute is used as a fallback.
Error reporting would improve slightly if just the span of the deprecation note would be used. That requires that that span is stored, and then used in
report_diagnostic.