1 error[E0603]: tuple struct constructor `A` is private
2 --> $DIR/suggest-making-field-public.rs:13:8
4 LL | pub struct A(pub(self)String);
5 | --------------- a constructor is private if any of the fields is private
8 | ^ private tuple struct constructor
10 note: the tuple struct constructor `A` is defined here
11 --> $DIR/suggest-making-field-public.rs:3:5
13 LL | pub struct A(pub(self)String);
14 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
15 help: consider making the field publicly accessible
17 LL | pub struct A(pub String);
20 error[E0423]: cannot initialize a tuple struct which contains private fields
21 --> $DIR/suggest-making-field-public.rs:9:9
26 note: constructor is not visible here due to private fields
27 --> $DIR/suggest-making-field-public.rs:3:18
29 LL | pub struct A(pub(self)String);
30 | ^^^^^^^^^^^^^^^ private field
31 help: consider making the field publicly accessible
33 LL | pub struct A(pub String);
36 error: aborting due to 2 previous errors
38 Some errors have detailed explanations: E0423, E0603.
39 For more information about an error, try `rustc --explain E0423`.