diff options
Diffstat (limited to '')
-rw-r--r-- | src/test/ui/issues/issue-75906.rs | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/src/test/ui/issues/issue-75906.rs b/src/test/ui/issues/issue-75906.rs new file mode 100644 index 000000000..710039d79 --- /dev/null +++ b/src/test/ui/issues/issue-75906.rs @@ -0,0 +1,13 @@ +mod m { + pub struct Foo { x: u8 } + + pub struct Bar(u8); +} + +use m::{Foo, Bar}; + +fn main() { + let x = Foo { x: 12 }; + let y = Bar(12); + //~^ ERROR cannot initialize a tuple struct which contains private fields [E0423] +} |