We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
doc_cfg
check_cfg
1 parent 28bd22c commit 85b1116Copy full SHA for 85b1116
tests/rustdoc-ui/doc-cfg-check-cfg.rs
@@ -0,0 +1,16 @@
1
+// Ensure that `doc(cfg())` respects `check-cfg`
2
+// Currently not properly working
3
+#![feature(doc_cfg)]
4
+#![deny(unexpected_cfgs)]
5
+
6
+//@revisions: no_check cfg_empty cfg_foo
7
+//@[cfg_empty] compile-flags: --check-cfg cfg()
8
+//@[cfg_foo] compile-flags: --check-cfg cfg(foo)
9
10
+//@[no_check] check-pass
11
+//@[cfg_empty] check-pass
12
+//@[cfg_empty] known-bug: #138358
13
+//@[cfg_foo] check-pass
14
15
+#[doc(cfg(foo))]
16
+pub fn foo() {}
0 commit comments