2023-06-17 02:06:48 -05:00
|
|
|
//@ run-rustfix
|
|
|
|
|
|
|
|
#![deny(unused_qualifications)]
|
|
|
|
|
|
|
|
mod foo {
|
|
|
|
pub fn bar() {}
|
|
|
|
}
|
|
|
|
|
|
|
|
mod baz {
|
|
|
|
pub mod qux {
|
|
|
|
pub fn quux() {}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
fn main() {
|
|
|
|
use foo::bar;
|
|
|
|
bar();
|
|
|
|
//~^ ERROR unnecessary qualification
|
2024-03-11 09:39:02 -05:00
|
|
|
bar();
|
2023-06-17 02:06:48 -05:00
|
|
|
|
|
|
|
use baz::qux::quux;
|
|
|
|
quux();
|
|
|
|
//~^ ERROR unnecessary qualification
|
2024-03-11 09:39:02 -05:00
|
|
|
quux();
|
2023-06-17 02:06:48 -05:00
|
|
|
}
|