From bf544fa920efb1614f95ebc783fbd11c07604972 Mon Sep 17 00:00:00 2001 From: "Felix S. Klock II" Date: Wed, 31 Oct 2018 00:18:11 +0100 Subject: [PATCH] remove `#[rustc_error]` from ui/ tests that remain compile-fail tests. --- src/test/ui/asm/asm-bad-clobber.rs | 4 ++-- .../coherence_copy_like_err_fundamental_struct_tuple.rs | 4 ++-- src/test/ui/coherence/coherence_local_err_struct.rs | 4 ++-- src/test/ui/coherence/coherence_local_err_tuple.rs | 4 ++-- src/test/ui/feature-gates/feature-gate-custom_attribute.rs | 4 ++-- src/test/ui/lifetimes/lifetime-bound-will-change-warning.rs | 4 ++-- src/test/ui/on-unimplemented/multiple-impls.rs | 4 ++-- src/test/ui/on-unimplemented/on-impl.rs | 4 ++-- src/test/ui/on-unimplemented/slice-index.rs | 4 ++-- .../ui/regions/regions-outlives-projection-container-hrtb.rs | 4 ++-- src/test/ui/retslot-cast.rs | 4 ++-- .../regions-outlives-nominal-type-region-rev.rs | 4 ++-- .../regions-outlives-nominal-type-region.rs | 4 ++-- .../regions-outlives-nominal-type-type-rev.rs | 4 ++-- .../regions-outlives-nominal-type-type.rs | 4 ++-- src/test/ui/variance/variance-btree-invariant-types.rs | 4 ++-- src/test/ui/variance/variance-use-contravariant-struct-1.rs | 4 ++-- src/test/ui/variance/variance-use-invariant-struct-1.rs | 4 ++-- src/test/ui/wf/wf-array-elem-sized.rs | 4 ++-- src/test/ui/wf/wf-const-type.rs | 4 ++-- src/test/ui/wf/wf-enum-bound.rs | 4 ++-- src/test/ui/wf/wf-enum-fields-struct-variant.rs | 4 ++-- src/test/ui/wf/wf-enum-fields.rs | 4 ++-- src/test/ui/wf/wf-fn-where-clause.rs | 4 ++-- src/test/ui/wf/wf-impl-associated-type-region.rs | 4 ++-- src/test/ui/wf/wf-impl-associated-type-trait.rs | 4 ++-- src/test/ui/wf/wf-in-fn-type-static.rs | 4 ++-- src/test/ui/wf/wf-in-fn-where-clause.rs | 4 ++-- src/test/ui/wf/wf-in-obj-type-static.rs | 4 ++-- src/test/ui/wf/wf-inherent-impl-method-where-clause.rs | 4 ++-- src/test/ui/wf/wf-inherent-impl-where-clause.rs | 4 ++-- src/test/ui/wf/wf-static-type.rs | 4 ++-- src/test/ui/wf/wf-struct-bound.rs | 4 ++-- src/test/ui/wf/wf-struct-field.rs | 4 ++-- src/test/ui/wf/wf-trait-associated-type-bound.rs | 4 ++-- src/test/ui/wf/wf-trait-associated-type-region.rs | 4 ++-- src/test/ui/wf/wf-trait-associated-type-trait.rs | 4 ++-- src/test/ui/wf/wf-trait-bound.rs | 4 ++-- src/test/ui/wf/wf-trait-default-fn-arg.rs | 4 ++-- src/test/ui/wf/wf-trait-default-fn-where-clause.rs | 4 ++-- src/test/ui/wf/wf-trait-fn-where-clause.rs | 4 ++-- 41 files changed, 82 insertions(+), 82 deletions(-) diff --git a/src/test/ui/asm/asm-bad-clobber.rs b/src/test/ui/asm/asm-bad-clobber.rs index c2b54e37e39..543eb2ac842 100644 --- a/src/test/ui/asm/asm-bad-clobber.rs +++ b/src/test/ui/asm/asm-bad-clobber.rs @@ -21,11 +21,11 @@ // ignore-mips // ignore-mips64 -#![feature(asm, rustc_attrs)] +#![feature(asm)] #[cfg(any(target_arch = "x86", target_arch = "x86_64"))] -#[rustc_error] + pub fn main() { unsafe { // clobber formatted as register input/output diff --git a/src/test/ui/coherence/coherence_copy_like_err_fundamental_struct_tuple.rs b/src/test/ui/coherence/coherence_copy_like_err_fundamental_struct_tuple.rs index f424e887201..ee6a61dca4a 100644 --- a/src/test/ui/coherence/coherence_copy_like_err_fundamental_struct_tuple.rs +++ b/src/test/ui/coherence/coherence_copy_like_err_fundamental_struct_tuple.rs @@ -13,7 +13,7 @@ // aux-build:coherence_copy_like_lib.rs -#![feature(rustc_attrs)] + extern crate coherence_copy_like_lib as lib; @@ -26,5 +26,5 @@ impl MyTrait for T { } // Tuples are not fundamental. impl MyTrait for lib::MyFundamentalStruct<(MyType,)> { } //~ ERROR E0119 -#[rustc_error] + fn main() { } diff --git a/src/test/ui/coherence/coherence_local_err_struct.rs b/src/test/ui/coherence/coherence_local_err_struct.rs index 01f4c1cd8a5..72772a6efbd 100644 --- a/src/test/ui/coherence/coherence_local_err_struct.rs +++ b/src/test/ui/coherence/coherence_local_err_struct.rs @@ -13,7 +13,7 @@ // aux-build:coherence_copy_like_lib.rs -#![feature(rustc_attrs)] + #![allow(dead_code)] extern crate coherence_copy_like_lib as lib; @@ -25,5 +25,5 @@ struct MyType { x: i32 } // MyStruct is not fundamental. impl lib::MyCopy for lib::MyStruct { } //~ ERROR E0117 -#[rustc_error] + fn main() { } diff --git a/src/test/ui/coherence/coherence_local_err_tuple.rs b/src/test/ui/coherence/coherence_local_err_tuple.rs index 590f68cee59..88e98c7ce00 100644 --- a/src/test/ui/coherence/coherence_local_err_tuple.rs +++ b/src/test/ui/coherence/coherence_local_err_tuple.rs @@ -13,7 +13,7 @@ // aux-build:coherence_copy_like_lib.rs -#![feature(rustc_attrs)] + #![allow(dead_code)] extern crate coherence_copy_like_lib as lib; @@ -25,5 +25,5 @@ struct MyType { x: i32 } // Tuples are not fundamental, so this is not a local impl. impl lib::MyCopy for (MyType,) { } //~ ERROR E0117 -#[rustc_error] + fn main() { } diff --git a/src/test/ui/feature-gates/feature-gate-custom_attribute.rs b/src/test/ui/feature-gates/feature-gate-custom_attribute.rs index ed8392ad7a3..4371de57776 100644 --- a/src/test/ui/feature-gates/feature-gate-custom_attribute.rs +++ b/src/test/ui/feature-gates/feature-gate-custom_attribute.rs @@ -10,7 +10,7 @@ // Check that literals in attributes parse just fine. -#![feature(rustc_attrs)] + #![allow(dead_code)] #![allow(unused_variables)] @@ -29,5 +29,5 @@ #[fake_doc(r"doc")] //~ ERROR attribute `fake_doc` is currently unknown struct Q { } -#[rustc_error] + fn main() { } diff --git a/src/test/ui/lifetimes/lifetime-bound-will-change-warning.rs b/src/test/ui/lifetimes/lifetime-bound-will-change-warning.rs index 7e9a4f82478..cd0ba5e4a0a 100644 --- a/src/test/ui/lifetimes/lifetime-bound-will-change-warning.rs +++ b/src/test/ui/lifetimes/lifetime-bound-will-change-warning.rs @@ -15,7 +15,7 @@ #![allow(dead_code)] #![allow(unused_variables)] -#![feature(rustc_attrs)] + extern crate lifetime_bound_will_change_warning_lib as lib; @@ -59,6 +59,6 @@ fn test3cc<'a>(x: &'a Box) { lib::ref_obj(x) } -#[rustc_error] + fn main() { } diff --git a/src/test/ui/on-unimplemented/multiple-impls.rs b/src/test/ui/on-unimplemented/multiple-impls.rs index 539f5d63c0b..4467ac4356b 100644 --- a/src/test/ui/on-unimplemented/multiple-impls.rs +++ b/src/test/ui/on-unimplemented/multiple-impls.rs @@ -11,7 +11,7 @@ // Test if the on_unimplemented message override works #![feature(on_unimplemented)] -#![feature(rustc_attrs)] + struct Foo(T); struct Bar(T); @@ -38,7 +38,7 @@ fn index(&self, _index: Bar) -> &i32 { } } -#[rustc_error] + fn main() { Index::index(&[] as &[i32], 2u32); //~^ ERROR E0277 diff --git a/src/test/ui/on-unimplemented/on-impl.rs b/src/test/ui/on-unimplemented/on-impl.rs index da56ae64993..d104d1ed033 100644 --- a/src/test/ui/on-unimplemented/on-impl.rs +++ b/src/test/ui/on-unimplemented/on-impl.rs @@ -11,7 +11,7 @@ // Test if the on_unimplemented message override works #![feature(on_unimplemented)] -#![feature(rustc_attrs)] + #[rustc_on_unimplemented = "invalid"] trait Index { @@ -27,7 +27,7 @@ fn index(&self, index: usize) -> &i32 { } } -#[rustc_error] + fn main() { Index::::index(&[1, 2, 3] as &[i32], 2u32); //~^ ERROR E0277 diff --git a/src/test/ui/on-unimplemented/slice-index.rs b/src/test/ui/on-unimplemented/slice-index.rs index 7d67e89a78e..79bb277d2c1 100644 --- a/src/test/ui/on-unimplemented/slice-index.rs +++ b/src/test/ui/on-unimplemented/slice-index.rs @@ -11,11 +11,11 @@ // Test new Index error message for slices // ignore-tidy-linelength -#![feature(rustc_attrs)] + use std::ops::Index; -#[rustc_error] + fn main() { let x = &[1, 2, 3] as &[i32]; x[1i32]; //~ ERROR E0277 diff --git a/src/test/ui/regions/regions-outlives-projection-container-hrtb.rs b/src/test/ui/regions/regions-outlives-projection-container-hrtb.rs index ec0631a881a..270e20f2e6d 100644 --- a/src/test/ui/regions/regions-outlives-projection-container-hrtb.rs +++ b/src/test/ui/regions/regions-outlives-projection-container-hrtb.rs @@ -12,7 +12,7 @@ // "outlives" requirements. Issue #22246. #![allow(dead_code)] -#![feature(rustc_attrs)] + /////////////////////////////////////////////////////////////////////////// @@ -64,6 +64,6 @@ fn with_assoc_sub<'a,'b>() { //~^ ERROR reference has a longer lifetime } -#[rustc_error] + fn main() { } diff --git a/src/test/ui/retslot-cast.rs b/src/test/ui/retslot-cast.rs index c5e26a26744..a4681633326 100644 --- a/src/test/ui/retslot-cast.rs +++ b/src/test/ui/retslot-cast.rs @@ -8,7 +8,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -#![feature(rustc_attrs)] + #![allow(warnings)] pub fn fail(x: Option<&(Iterator+Send)>) @@ -29,5 +29,5 @@ pub fn inner(x: Option<&(Iterator+Send)>) x } -#[rustc_error] + fn main() {} diff --git a/src/test/ui/rfc-2093-infer-outlives/regions-outlives-nominal-type-region-rev.rs b/src/test/ui/rfc-2093-infer-outlives/regions-outlives-nominal-type-region-rev.rs index 44af621ef24..77b5b401c42 100644 --- a/src/test/ui/rfc-2093-infer-outlives/regions-outlives-nominal-type-region-rev.rs +++ b/src/test/ui/rfc-2093-infer-outlives/regions-outlives-nominal-type-region-rev.rs @@ -13,7 +13,7 @@ // // Rule OutlivesNominalType from RFC 1214. -#![feature(rustc_attrs)] + #![allow(dead_code)] mod rev_variant_struct_region { @@ -28,5 +28,5 @@ impl<'a, 'b> Trait<'a, 'b> for usize { } } -#[rustc_error] + fn main() { } diff --git a/src/test/ui/rfc-2093-infer-outlives/regions-outlives-nominal-type-region.rs b/src/test/ui/rfc-2093-infer-outlives/regions-outlives-nominal-type-region.rs index 93f16350a7b..b6ac7aa3a9c 100644 --- a/src/test/ui/rfc-2093-infer-outlives/regions-outlives-nominal-type-region.rs +++ b/src/test/ui/rfc-2093-infer-outlives/regions-outlives-nominal-type-region.rs @@ -13,7 +13,7 @@ // // Rule OutlivesNominalType from RFC 1214. -#![feature(rustc_attrs)] + #![allow(dead_code)] mod variant_struct_region { @@ -28,5 +28,5 @@ impl<'a, 'b> Trait<'a, 'b> for usize { } } -#[rustc_error] + fn main() { } diff --git a/src/test/ui/rfc-2093-infer-outlives/regions-outlives-nominal-type-type-rev.rs b/src/test/ui/rfc-2093-infer-outlives/regions-outlives-nominal-type-type-rev.rs index e44e049a9e5..3f7d086a6ae 100644 --- a/src/test/ui/rfc-2093-infer-outlives/regions-outlives-nominal-type-type-rev.rs +++ b/src/test/ui/rfc-2093-infer-outlives/regions-outlives-nominal-type-type-rev.rs @@ -13,7 +13,7 @@ // // Rule OutlivesNominalType from RFC 1214. -#![feature(rustc_attrs)] + #![allow(dead_code)] mod variant_struct_type { @@ -28,5 +28,5 @@ impl<'a, 'b> Trait<'a, 'b> for usize { } } -#[rustc_error] + fn main() { } diff --git a/src/test/ui/rfc-2093-infer-outlives/regions-outlives-nominal-type-type.rs b/src/test/ui/rfc-2093-infer-outlives/regions-outlives-nominal-type-type.rs index 1293e6c234b..dff9b8a862f 100644 --- a/src/test/ui/rfc-2093-infer-outlives/regions-outlives-nominal-type-type.rs +++ b/src/test/ui/rfc-2093-infer-outlives/regions-outlives-nominal-type-type.rs @@ -13,7 +13,7 @@ // // Rule OutlivesNominalType from RFC 1214. -#![feature(rustc_attrs)] + #![allow(dead_code)] mod variant_struct_type { @@ -28,5 +28,5 @@ impl<'a, 'b> Trait<'a, 'b> for usize { } } -#[rustc_error] + fn main() { } diff --git a/src/test/ui/variance/variance-btree-invariant-types.rs b/src/test/ui/variance/variance-btree-invariant-types.rs index e9607de00a3..59fc0136612 100644 --- a/src/test/ui/variance/variance-btree-invariant-types.rs +++ b/src/test/ui/variance/variance-btree-invariant-types.rs @@ -8,7 +8,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -#![feature(rustc_attrs)] + use std::collections::btree_map::{IterMut, OccupiedEntry, VacantEntry}; @@ -59,5 +59,5 @@ fn vac_contra_val<'a, 'new>(v: VacantEntry<'a, (), &'new ()>) v //~ ERROR mismatched types } -#[rustc_error] + fn main() { } diff --git a/src/test/ui/variance/variance-use-contravariant-struct-1.rs b/src/test/ui/variance/variance-use-contravariant-struct-1.rs index d2fd2978750..47ecec5a112 100644 --- a/src/test/ui/variance/variance-use-contravariant-struct-1.rs +++ b/src/test/ui/variance/variance-use-contravariant-struct-1.rs @@ -11,7 +11,7 @@ // Test various uses of structs with distint variances to make sure // they permit lifetimes to be approximated as expected. -#![feature(rustc_attrs)] + struct SomeStruct(fn(T)); @@ -22,5 +22,5 @@ fn foo<'min,'max>(v: SomeStruct<&'max ()>) v //~ ERROR mismatched types } -#[rustc_error] + fn main() { } diff --git a/src/test/ui/variance/variance-use-invariant-struct-1.rs b/src/test/ui/variance/variance-use-invariant-struct-1.rs index c89436b2094..2e6c0c16dcd 100644 --- a/src/test/ui/variance/variance-use-invariant-struct-1.rs +++ b/src/test/ui/variance/variance-use-invariant-struct-1.rs @@ -11,7 +11,7 @@ // Test various uses of structs with distint variances to make sure // they permit lifetimes to be approximated as expected. -#![feature(rustc_attrs)] + struct SomeStruct(*mut T); @@ -29,5 +29,5 @@ fn bar<'min,'max>(v: SomeStruct<&'min ()>) v //~ ERROR mismatched types } -#[rustc_error] + fn main() { } diff --git a/src/test/ui/wf/wf-array-elem-sized.rs b/src/test/ui/wf/wf-array-elem-sized.rs index 946341a1a75..36e9226ae3f 100644 --- a/src/test/ui/wf/wf-array-elem-sized.rs +++ b/src/test/ui/wf/wf-array-elem-sized.rs @@ -10,12 +10,12 @@ // Check that array elemen types must be Sized. Issue #25692. -#![feature(rustc_attrs)] + #![allow(dead_code)] struct Foo { foo: [[u8]], //~ ERROR E0277 } -#[rustc_error] + fn main() { } diff --git a/src/test/ui/wf/wf-const-type.rs b/src/test/ui/wf/wf-const-type.rs index c3015afd8dd..bc14ce46ff1 100644 --- a/src/test/ui/wf/wf-const-type.rs +++ b/src/test/ui/wf/wf-const-type.rs @@ -11,7 +11,7 @@ // Test that we check the types of constants are well-formed. #![feature(associated_type_defaults)] -#![feature(rustc_attrs)] + #![allow(dead_code)] struct IsCopy { t: T } @@ -20,5 +20,5 @@ struct IsCopy { t: T } const FOO: IsCopy> = IsCopy { t: None }; //~^ ERROR E0277 -#[rustc_error] + fn main() { } diff --git a/src/test/ui/wf/wf-enum-bound.rs b/src/test/ui/wf/wf-enum-bound.rs index e3e79fdd940..6c08f5a4a54 100644 --- a/src/test/ui/wf/wf-enum-bound.rs +++ b/src/test/ui/wf/wf-enum-bound.rs @@ -11,7 +11,7 @@ // Test that we check enum bounds for WFedness. #![feature(associated_type_defaults)] -#![feature(rustc_attrs)] + #![allow(dead_code)] trait ExtraCopy { } @@ -22,5 +22,5 @@ enum SomeEnum //~ ERROR E0277 SomeVariant(T,U) } -#[rustc_error] + fn main() { } diff --git a/src/test/ui/wf/wf-enum-fields-struct-variant.rs b/src/test/ui/wf/wf-enum-fields-struct-variant.rs index 5eb53e7edde..572b609fe2e 100644 --- a/src/test/ui/wf/wf-enum-fields-struct-variant.rs +++ b/src/test/ui/wf/wf-enum-fields-struct-variant.rs @@ -11,7 +11,7 @@ // Test that we check struct fields for WFedness. #![feature(associated_type_defaults)] -#![feature(rustc_attrs)] + #![allow(dead_code)] struct IsCopy { @@ -24,5 +24,5 @@ enum AnotherEnum { } } -#[rustc_error] + fn main() { } diff --git a/src/test/ui/wf/wf-enum-fields.rs b/src/test/ui/wf/wf-enum-fields.rs index 76ad40f8457..32e870e9e1b 100644 --- a/src/test/ui/wf/wf-enum-fields.rs +++ b/src/test/ui/wf/wf-enum-fields.rs @@ -11,7 +11,7 @@ // Test that we check struct fields for WFedness. #![feature(associated_type_defaults)] -#![feature(rustc_attrs)] + #![allow(dead_code)] struct IsCopy { @@ -22,5 +22,5 @@ enum SomeEnum { SomeVariant(IsCopy) //~ ERROR E0277 } -#[rustc_error] + fn main() { } diff --git a/src/test/ui/wf/wf-fn-where-clause.rs b/src/test/ui/wf/wf-fn-where-clause.rs index 59bb8326ddb..3d97bdb521f 100644 --- a/src/test/ui/wf/wf-fn-where-clause.rs +++ b/src/test/ui/wf/wf-fn-where-clause.rs @@ -10,7 +10,7 @@ // Test that we check where-clauses on fn items. -#![feature(rustc_attrs)] + #![allow(dead_code)] trait ExtraCopy { } @@ -23,5 +23,5 @@ fn bar() where Vec:, {} //~^ ERROR E0277 //~| ERROR E0038 -#[rustc_error] + fn main() { } diff --git a/src/test/ui/wf/wf-impl-associated-type-region.rs b/src/test/ui/wf/wf-impl-associated-type-region.rs index a319b676eeb..aa88b3d7377 100644 --- a/src/test/ui/wf/wf-impl-associated-type-region.rs +++ b/src/test/ui/wf/wf-impl-associated-type-region.rs @@ -10,7 +10,7 @@ // Check that we require that associated types in an impl are well-formed. -#![feature(rustc_attrs)] + pub trait Foo<'a> { type Bar; @@ -20,5 +20,5 @@ impl<'a, T> Foo<'a> for T { type Bar = &'a T; //~ ERROR E0309 } -#[rustc_error] + fn main() { } diff --git a/src/test/ui/wf/wf-impl-associated-type-trait.rs b/src/test/ui/wf/wf-impl-associated-type-trait.rs index 1e82f609d2a..0b5a76db262 100644 --- a/src/test/ui/wf/wf-impl-associated-type-trait.rs +++ b/src/test/ui/wf/wf-impl-associated-type-trait.rs @@ -10,7 +10,7 @@ // Check that we require that associated types in an impl are well-formed. -#![feature(rustc_attrs)] + #![allow(dead_code)] pub trait MyHash { } @@ -28,5 +28,5 @@ impl Foo for T { //~^ ERROR the trait bound `T: MyHash` is not satisfied } -#[rustc_error] + fn main() { } diff --git a/src/test/ui/wf/wf-in-fn-type-static.rs b/src/test/ui/wf/wf-in-fn-type-static.rs index 8e3bca09758..dfe6688c0b7 100644 --- a/src/test/ui/wf/wf-in-fn-type-static.rs +++ b/src/test/ui/wf/wf-in-fn-type-static.rs @@ -12,7 +12,7 @@ // types in fns. #![allow(dead_code)] -#![feature(rustc_attrs)] + struct MustBeCopy { t: T @@ -28,5 +28,5 @@ struct Bar { x: fn(&'static T) //~ ERROR E0310 } -#[rustc_error] + fn main() { } diff --git a/src/test/ui/wf/wf-in-fn-where-clause.rs b/src/test/ui/wf/wf-in-fn-where-clause.rs index c2f66a2a460..f6f14099e73 100644 --- a/src/test/ui/wf/wf-in-fn-where-clause.rs +++ b/src/test/ui/wf/wf-in-fn-where-clause.rs @@ -10,7 +10,7 @@ // Check that we enforce WF conditions also for where clauses in fn items. -#![feature(rustc_attrs)] + #![allow(dead_code)] trait MustBeCopy { @@ -21,5 +21,5 @@ fn bar() //~ ERROR E0277 { } -#[rustc_error] + fn main() { } diff --git a/src/test/ui/wf/wf-in-obj-type-static.rs b/src/test/ui/wf/wf-in-obj-type-static.rs index 11535fb9f9e..7cbcf99af3c 100644 --- a/src/test/ui/wf/wf-in-obj-type-static.rs +++ b/src/test/ui/wf/wf-in-obj-type-static.rs @@ -10,7 +10,7 @@ // Check that we enforce WF conditions also for types in fns. -#![feature(rustc_attrs)] + #![allow(dead_code)] trait Object { } @@ -24,5 +24,5 @@ struct Foo { x: Object<&'static T> //~ ERROR E0310 } -#[rustc_error] + fn main() { } diff --git a/src/test/ui/wf/wf-inherent-impl-method-where-clause.rs b/src/test/ui/wf/wf-inherent-impl-method-where-clause.rs index 78e12c47e24..8b65b2e1626 100644 --- a/src/test/ui/wf/wf-inherent-impl-method-where-clause.rs +++ b/src/test/ui/wf/wf-inherent-impl-method-where-clause.rs @@ -11,7 +11,7 @@ // Test that we check where-clauses on inherent impl methods. #![feature(associated_type_defaults)] -#![feature(rustc_attrs)] + #![allow(dead_code)] trait ExtraCopy { } @@ -23,5 +23,5 @@ fn foo(self) where T: ExtraCopy //~ ERROR E0277 {} } -#[rustc_error] + fn main() { } diff --git a/src/test/ui/wf/wf-inherent-impl-where-clause.rs b/src/test/ui/wf/wf-inherent-impl-where-clause.rs index 7edbb11e245..ee929282849 100644 --- a/src/test/ui/wf/wf-inherent-impl-where-clause.rs +++ b/src/test/ui/wf/wf-inherent-impl-where-clause.rs @@ -11,7 +11,7 @@ // Test that we check where-clauses on inherent impls. #![feature(associated_type_defaults)] -#![feature(rustc_attrs)] + #![allow(dead_code)] trait ExtraCopy { } @@ -22,5 +22,5 @@ impl Foo where T: ExtraCopy //~ ERROR E0277 { } -#[rustc_error] + fn main() { } diff --git a/src/test/ui/wf/wf-static-type.rs b/src/test/ui/wf/wf-static-type.rs index ba02c5dca3e..91943b44d97 100644 --- a/src/test/ui/wf/wf-static-type.rs +++ b/src/test/ui/wf/wf-static-type.rs @@ -11,7 +11,7 @@ // Test that we check the types of statics are well-formed. #![feature(associated_type_defaults)] -#![feature(rustc_attrs)] + #![allow(dead_code)] struct IsCopy { t: T } @@ -20,5 +20,5 @@ struct IsCopy { t: T } static FOO: IsCopy> = IsCopy { t: None }; //~^ ERROR E0277 -#[rustc_error] + fn main() { } diff --git a/src/test/ui/wf/wf-struct-bound.rs b/src/test/ui/wf/wf-struct-bound.rs index e263b251aa3..c4a15bbe540 100644 --- a/src/test/ui/wf/wf-struct-bound.rs +++ b/src/test/ui/wf/wf-struct-bound.rs @@ -11,7 +11,7 @@ // Test that we check struct bounds for WFedness. #![feature(associated_type_defaults)] -#![feature(rustc_attrs)] + #![allow(dead_code)] trait ExtraCopy { } @@ -22,5 +22,5 @@ struct SomeStruct //~ ERROR E0277 data: (T,U) } -#[rustc_error] + fn main() { } diff --git a/src/test/ui/wf/wf-struct-field.rs b/src/test/ui/wf/wf-struct-field.rs index 8a631a6c335..4d1e42829d8 100644 --- a/src/test/ui/wf/wf-struct-field.rs +++ b/src/test/ui/wf/wf-struct-field.rs @@ -11,7 +11,7 @@ // Test that we check struct fields for WFedness. #![feature(associated_type_defaults)] -#![feature(rustc_attrs)] + #![allow(dead_code)] struct IsCopy { @@ -22,5 +22,5 @@ struct SomeStruct { data: IsCopy //~ ERROR E0277 } -#[rustc_error] + fn main() { } diff --git a/src/test/ui/wf/wf-trait-associated-type-bound.rs b/src/test/ui/wf/wf-trait-associated-type-bound.rs index 8420edd66a1..eaeffa01740 100644 --- a/src/test/ui/wf/wf-trait-associated-type-bound.rs +++ b/src/test/ui/wf/wf-trait-associated-type-bound.rs @@ -11,7 +11,7 @@ // Test that we check associated type bounds for WFedness. #![feature(associated_type_defaults)] -#![feature(rustc_attrs)] + #![allow(dead_code)] trait ExtraCopy { } @@ -20,5 +20,5 @@ trait SomeTrait { //~ ERROR E0277 type Type1: ExtraCopy; } -#[rustc_error] + fn main() { } diff --git a/src/test/ui/wf/wf-trait-associated-type-region.rs b/src/test/ui/wf/wf-trait-associated-type-region.rs index 95d9ffdf9d3..61cdbe5e491 100644 --- a/src/test/ui/wf/wf-trait-associated-type-region.rs +++ b/src/test/ui/wf/wf-trait-associated-type-region.rs @@ -11,7 +11,7 @@ // Test that we check associated type default values for WFedness. #![feature(associated_type_defaults)] -#![feature(rustc_attrs)] + #![allow(dead_code)] trait SomeTrait<'a> { @@ -20,5 +20,5 @@ trait SomeTrait<'a> { //~^ ERROR E0309 } -#[rustc_error] + fn main() { } diff --git a/src/test/ui/wf/wf-trait-associated-type-trait.rs b/src/test/ui/wf/wf-trait-associated-type-trait.rs index 902cbe2676b..e752c0a9077 100644 --- a/src/test/ui/wf/wf-trait-associated-type-trait.rs +++ b/src/test/ui/wf/wf-trait-associated-type-trait.rs @@ -11,7 +11,7 @@ // Test that we check associated type default values for WFedness. #![feature(associated_type_defaults)] -#![feature(rustc_attrs)] + #![allow(dead_code)] struct IsCopy { x: T } @@ -22,5 +22,5 @@ trait SomeTrait { //~^ ERROR E0277 } -#[rustc_error] + fn main() { } diff --git a/src/test/ui/wf/wf-trait-bound.rs b/src/test/ui/wf/wf-trait-bound.rs index ca15a6ab648..c02281ab4f9 100644 --- a/src/test/ui/wf/wf-trait-bound.rs +++ b/src/test/ui/wf/wf-trait-bound.rs @@ -11,7 +11,7 @@ // Test that we check supertrait bounds for WFedness. #![feature(associated_type_defaults)] -#![feature(rustc_attrs)] + #![allow(dead_code)] trait ExtraCopy { } @@ -21,5 +21,5 @@ trait SomeTrait //~ ERROR E0277 { } -#[rustc_error] + fn main() { } diff --git a/src/test/ui/wf/wf-trait-default-fn-arg.rs b/src/test/ui/wf/wf-trait-default-fn-arg.rs index 453aa2428ce..8577bc89638 100644 --- a/src/test/ui/wf/wf-trait-default-fn-arg.rs +++ b/src/test/ui/wf/wf-trait-default-fn-arg.rs @@ -11,7 +11,7 @@ // Check that we test WF conditions for fn arguments. Because the // current code is so goofy, this is only a warning for now. -#![feature(rustc_attrs)] + #![allow(dead_code)] #![allow(unused_variables)] @@ -25,5 +25,5 @@ fn bar(&self, x: &Bar) { } } -#[rustc_error] + fn main() { } diff --git a/src/test/ui/wf/wf-trait-default-fn-where-clause.rs b/src/test/ui/wf/wf-trait-default-fn-where-clause.rs index 29c85250583..b1576719870 100644 --- a/src/test/ui/wf/wf-trait-default-fn-where-clause.rs +++ b/src/test/ui/wf/wf-trait-default-fn-where-clause.rs @@ -11,7 +11,7 @@ // Check that we test WF conditions for fn arguments. Because the // current code is so goofy, this is only a warning for now. -#![feature(rustc_attrs)] + #![allow(dead_code)] #![allow(unused_variables)] @@ -25,5 +25,5 @@ fn bar(&self) where A: Bar { } } -#[rustc_error] + fn main() { } diff --git a/src/test/ui/wf/wf-trait-fn-where-clause.rs b/src/test/ui/wf/wf-trait-fn-where-clause.rs index f46a54504a0..44e3d6bda5c 100644 --- a/src/test/ui/wf/wf-trait-fn-where-clause.rs +++ b/src/test/ui/wf/wf-trait-fn-where-clause.rs @@ -10,7 +10,7 @@ // Check that we test WF conditions for fn where clauses in a trait definition. -#![feature(rustc_attrs)] + #![allow(dead_code)] #![allow(unused_variables)] @@ -23,5 +23,5 @@ trait Foo { // Here, Eq ought to be implemented. } -#[rustc_error] + fn main() { } -- GitLab