]> git.lizzy.rs Git - rust.git/blob - src/test/ui/error-codes/ex-E0611.rs
Merge commit 'd3a2366ee877075c59b38bd8ced55f224fc7ef51' into sync_cg_clif-2022-07-26
[rust.git] / src / test / ui / error-codes / ex-E0611.rs
1 mod a {
2     pub struct Foo(u32);
3
4     impl Foo {
5         pub fn new() -> Foo { Foo(0) }
6     }
7 }
8
9 fn main() {
10    let y = a::Foo::new();
11    y.0; //~ ERROR field `0` of struct `Foo` is private
12 }