unused import false positive with macro rules macro #130570
Labels
A-diagnostics
Area: Messages for errors, warnings, and lints
C-discussion
Category: Discussion or questions that doesn't represent real issues.
L-unused_imports
Lint: unused_imports
T-compiler
Relevant to the compiler team, which will review and decide on the PR/issue.
T-rustdoc
Relevant to the rustdoc team, which will review and decide on the PR/issue.
Steps
Current output
Desired output
No warning
Rationale and extra context
use
on the name of a macro_rules macro is useful to give the macro path scope. In this case, the macro ends up being used by a rustdoc.Other cases
To show that the warning is incorrect:
which produces
Rust Version
Anything else?
clippy also complains about this; see rust-lang/rust-clippy#13419
The text was updated successfully, but these errors were encountered: