File tree 1 file changed +25
-0
lines changed
1 file changed +25
-0
lines changed Original file line number Diff line number Diff line change 1
1
// compile-flags: --document-private-items
2
2
3
3
#![ crate_name = "foo" ]
4
+ #![ feature( inherent_associated_types) ]
5
+ #![ allow( incomplete_features) ]
4
6
5
7
// @!has 'foo/index.html' '//a[@href="struct.FooPublic.html"]/..' 'FooPublic 🔒'
6
8
// @has 'foo/struct.FooPublic.html' '//pre' 'pub struct FooPublic'
@@ -103,3 +105,26 @@ impl PubTrait for FooPublic {
103
105
const CONST : usize = 0 ;
104
106
fn function ( ) { }
105
107
}
108
+
109
+ pub struct Assoc ;
110
+
111
+ // @has foo/struct.Assoc.html
112
+ impl Assoc {
113
+ // @has - '//*[@id="associatedtype.TypePub"]' 'pub type TypePub'
114
+ pub type TypePub = usize ;
115
+
116
+ // @has - '//*[@id="associatedtype.TypePriv"]' 'pub(crate) type TypePriv'
117
+ type TypePriv = usize ;
118
+
119
+ // @has - '//*[@id="associatedconstant.CONST_PUB"]' 'pub const CONST_PUB'
120
+ pub const CONST_PUB : usize = 0 ;
121
+
122
+ // @has - '//*[@id="associatedconstant.CONST_PRIV"]' 'pub(crate) const CONST_PRIV'
123
+ const CONST_PRIV : usize = 0 ;
124
+
125
+ // @has - '//*[@id="method.function_pub"]' 'pub fn function_pub()'
126
+ pub fn function_pub ( ) { }
127
+
128
+ // @has - '//*[@id="method.function_priv"]' 'pub(crate) fn function_priv()'
129
+ fn function_priv ( ) { }
130
+ }
You can’t perform that action at this time.
0 commit comments