summaryrefslogtreecommitdiffstats
path: root/src/test/ui/check-cfg/allow-at-crate-level.rs
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--src/test/ui/check-cfg/allow-at-crate-level.rs8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/test/ui/check-cfg/allow-at-crate-level.rs b/src/test/ui/check-cfg/allow-at-crate-level.rs
new file mode 100644
index 000000000..ce3383a29
--- /dev/null
+++ b/src/test/ui/check-cfg/allow-at-crate-level.rs
@@ -0,0 +1,8 @@
+// This test check that #![allow(unexpected_cfgs)] works with --cfg
+//
+// check-pass
+// compile-flags: --cfg=unexpected --check-cfg=names() -Z unstable-options
+
+#![allow(unexpected_cfgs)]
+
+fn main() {}