2018-08-08 07:28:26 -05:00
|
|
|
error[E0446]: private type `foo::Priv` in public interface
|
2018-12-25 09:56:47 -06:00
|
|
|
--> $DIR/private-in-public.rs:8:9
|
2018-08-08 07:28:26 -05:00
|
|
|
|
|
|
|
|
LL | struct Priv;
|
|
|
|
| - `foo::Priv` declared as private
|
|
|
|
...
|
|
|
|
LL | pub(crate) fn g(_: Priv) {} //~ ERROR E0446
|
|
|
|
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^ can't leak private type
|
|
|
|
|
|
|
|
error[E0446]: private type `foo::Priv` in public interface
|
2018-12-25 09:56:47 -06:00
|
|
|
--> $DIR/private-in-public.rs:9:9
|
2018-08-08 07:28:26 -05:00
|
|
|
|
|
|
|
|
LL | struct Priv;
|
|
|
|
| - `foo::Priv` declared as private
|
|
|
|
...
|
|
|
|
LL | crate fn h(_: Priv) {} //~ ERROR E0446
|
|
|
|
| ^^^^^^^^^^^^^^^^^^^^^^ can't leak private type
|
|
|
|
|
|
|
|
error: aborting due to 2 previous errors
|
|
|
|
|
|
|
|
For more information about this error, try `rustc --explain E0446`.
|