mirror of
https://github.com/rust-lang/rust.git
synced 2025-09-30 08:16:56 +00:00
16 lines
262 B
Rust
16 lines
262 B
Rust
//! Test that duplicate use bindings in same namespace produce error
|
|
|
|
mod foo {
|
|
pub use self::bar::X;
|
|
use self::bar::X;
|
|
//~^ ERROR the name `X` is defined multiple times
|
|
|
|
mod bar {
|
|
pub struct X;
|
|
}
|
|
}
|
|
|
|
fn main() {
|
|
let _ = foo::X;
|
|
}
|