2015-11-26 11:56:20 -06:00
|
|
|
mod m1 {
|
|
|
|
pub struct Pub;
|
|
|
|
struct Priv;
|
|
|
|
|
|
|
|
impl Pub {
|
2016-11-12 04:24:17 -06:00
|
|
|
pub fn f() -> Priv {Priv} //~ ERROR private type `m1::Priv` in public interface
|
2015-11-26 11:56:20 -06:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
mod m2 {
|
|
|
|
pub struct Pub;
|
|
|
|
struct Priv;
|
|
|
|
|
|
|
|
impl Pub {
|
2016-11-12 04:24:17 -06:00
|
|
|
pub fn f() -> Priv {Priv} //~ ERROR private type `m2::Priv` in public interface
|
2015-11-26 11:56:20 -06:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
fn main() {}
|