False positive #[warn(unused_imports)]
warning while glob importing macros defined in nested modules
#115966
Labels
A-diagnostics
Area: Messages for errors, warnings, and lints
C-bug
Category: This is a bug.
D-incorrect
Diagnostics: A diagnostic that is giving misleading or incorrect information.
T-compiler
Relevant to the compiler team, which will review and decide on the PR/issue.
I tried this code:
I expected to see this happen: No warning generated
Instead, this happened:
cargo check
generated such warningThough the warning says that glob import doesn't reexport anything, commenting out this line leads to error:
The warning will not be generated when any other pub functions are added into module b and exported. It happens when the module only exports macros.
Meta
rustc --version --verbose
:The text was updated successfully, but these errors were encountered: