rust/tests/ui/lint/use-redundant/use-redundant-glob-parent.rs
2024-07-31 00:07:42 -04:00

17 lines
244 B
Rust

//@ check-pass
#![warn(redundant_imports)]
pub mod bar {
pub struct Foo(pub Bar);
pub struct Bar(pub char);
}
use bar::*;
pub fn warning() -> Foo {
use bar::Foo; //~ WARNING imported redundantly
Foo(Bar('a'))
}
fn main() {}