There was an error while loading. Please reload this page.
unused_attributes
1 parent 6380899 commit e3dd4c1Copy full SHA for e3dd4c1
src/tools/compiletest/src/runtest.rs
@@ -1838,8 +1838,9 @@ impl<'test> TestCx<'test> {
1838
1839
// Add `-A unused` before `config` flags and in-test (`props`) flags, so that they can
1840
// overwrite this.
1841
+ // Don't allow `unused_attributes` since these are usually actual mistakes, rather than just unused code.
1842
if let AllowUnused::Yes = allow_unused {
- rustc.args(&["-A", "unused"]);
1843
+ rustc.args(&["-A", "unused", "-W", "unused_attributes"]);
1844
}
1845
1846
// Allow tests to use internal features.
0 commit comments