We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent e37e15d commit 4de29c9Copy full SHA for 4de29c9
tests/rustdoc/doc-hidden-crate.rs
@@ -0,0 +1,27 @@
1
+// Regression test for <https://github.com/rust-lang/rust/issues/126796>.
2
+// `doc(hidden)` should still be able to hide extern crates, only the local crates
3
+// cannot be hidden because we still need to generate its `index.html` file.
4
+
5
+#![crate_name = "foo"]
6
+#![doc(hidden)]
7
8
+//@ has 'foo/index.html'
9
+// First we check that the page contains the crate name (`foo`).
10
+//@ has - '//*' 'foo'
11
+// But doesn't contain any of the other items.
12
+//@ !has - '//*' 'other'
13
+//@ !has - '//*' 'marker'
14
+//@ !has - '//*' 'PhantomData'
15
16
+#[doc(inline)]
17
+pub use std as other;
18
19
20
+pub use std::marker;
21
22
23
+pub use std::marker::PhantomData;
24
25
+//@ !has - '//*' 'myself'
26
27
+pub use crate as myself;
0 commit comments