mirror of
https://github.com/rust-lang/rust.git
synced 2024-12-18 03:25:55 +00:00
ad13d9fbbe
Fix #52144.
22 lines
374 B
Rust
22 lines
374 B
Rust
mod foo {
|
|
pub struct Bx(pub(in crate::foo) ());
|
|
}
|
|
|
|
mod bar {
|
|
use foo::Bx;
|
|
|
|
fn foo() {
|
|
Bx(());
|
|
//~^ ERROR cannot initialize a tuple struct which contains private fields [E0423]
|
|
}
|
|
}
|
|
|
|
mod baz {
|
|
fn foo() {
|
|
Bx(());
|
|
//~^ ERROR cannot find function, tuple struct or tuple variant `Bx` in this scope [E0425]
|
|
}
|
|
}
|
|
|
|
fn main() {}
|