summaryrefslogtreecommitdiffstats
path: root/tests/ui/privacy/auxiliary/ctor_aux.rs
blob: 9c99cca9ae6edc1c49cb637635ab99a52aa7aa37 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
// edition:2021
//! Missing docs lint warns about undocumented exported items.
//! Use the lint to additionally verify that items are reachable
//! but not exported.
#![allow(non_camel_case_types)]
#![deny(missing_docs)]

mod hidden {
    pub struct s;
    pub enum e { x, y, z }
    pub use e::*;
    impl s {
        pub fn f(&self) {}
    }
    impl e {
        pub fn g(&self) {}
    }
}
// Hide all type definitions while reexporting their constructors:
mod e {}
mod x {}
mod y {}
mod z {}
mod s {}
pub use hidden::*;