There was an error while loading. Please reload this page.
1 parent 88ba7fb commit 4aeda22Copy full SHA for 4aeda22
1 file changed
tests/rustdoc-ui/lints/unused.rs
@@ -1,11 +1,13 @@
1
+//@ revisions: unused_attr unused_cli
2
+//@[unused_cli] compile-flags: -Dunused_imports
3
//@ check-pass
4
5
// This test purpose is to check that unused_imports lint isn't fired
6
// by rustdoc. Why would it? Because when rustdoc is running, it uses
7
// "everybody-loops" which replaces parts of code with "loop {}" to get
8
// huge performance improvements.
9
-#![deny(unused_imports)]
10
+#![cfg_attr(unused_attr, deny(unused_imports))]
11
12
use std::fs::File;
13
0 commit comments