diff options
Diffstat (limited to '')
30 files changed, 38 insertions, 45 deletions
diff --git a/tests/ui/attributes/attr-eq-token-tree.stderr b/tests/ui/attributes/attr-eq-token-tree.stderr index 1846444b6..d642e168e 100644 --- a/tests/ui/attributes/attr-eq-token-tree.stderr +++ b/tests/ui/attributes/attr-eq-token-tree.stderr @@ -4,5 +4,5 @@ error: expected expression, found `]` LL | #[my_attr = !] | ^ expected expression -error: aborting due to previous error +error: aborting due to 1 previous error diff --git a/tests/ui/attributes/attrs-with-no-formal-in-generics-1.stderr b/tests/ui/attributes/attrs-with-no-formal-in-generics-1.stderr index 5b4f5222a..6377d27f4 100644 --- a/tests/ui/attributes/attrs-with-no-formal-in-generics-1.stderr +++ b/tests/ui/attributes/attrs-with-no-formal-in-generics-1.stderr @@ -4,5 +4,5 @@ error: trailing attribute after generic parameter LL | impl<#[rustc_dummy] 'a, 'b, #[oops]> RefIntPair<'a, 'b> { | ^^^^^^^ attributes must go before parameters -error: aborting due to previous error +error: aborting due to 1 previous error diff --git a/tests/ui/attributes/attrs-with-no-formal-in-generics-2.stderr b/tests/ui/attributes/attrs-with-no-formal-in-generics-2.stderr index fce3ff7de..3224da58a 100644 --- a/tests/ui/attributes/attrs-with-no-formal-in-generics-2.stderr +++ b/tests/ui/attributes/attrs-with-no-formal-in-generics-2.stderr @@ -4,5 +4,5 @@ error: trailing attribute after generic parameter LL | impl<#[rustc_dummy] 'a, #[rustc_dummy] T, #[oops]> RefAny<'a, T> {} | ^^^^^^^ attributes must go before parameters -error: aborting due to previous error +error: aborting due to 1 previous error diff --git a/tests/ui/attributes/attrs-with-no-formal-in-generics-3.stderr b/tests/ui/attributes/attrs-with-no-formal-in-generics-3.stderr index b9ca00974..996df10a7 100644 --- a/tests/ui/attributes/attrs-with-no-formal-in-generics-3.stderr +++ b/tests/ui/attributes/attrs-with-no-formal-in-generics-3.stderr @@ -4,5 +4,5 @@ error: trailing attribute after generic parameter LL | where Q: for <#[allow(unused)] 'a, 'b, #[oops]> Fn(RefIntPair<'a,'b>) -> &'b u32 | ^^^^^^^ attributes must go before parameters -error: aborting due to previous error +error: aborting due to 1 previous error diff --git a/tests/ui/attributes/doc-test-literal.stderr b/tests/ui/attributes/doc-test-literal.stderr index ebee09994..ed2964825 100644 --- a/tests/ui/attributes/doc-test-literal.stderr +++ b/tests/ui/attributes/doc-test-literal.stderr @@ -13,5 +13,5 @@ LL | #![deny(warnings)] | ^^^^^^^^ = note: `#[deny(invalid_doc_attributes)]` implied by `#[deny(warnings)]` -error: aborting due to previous error +error: aborting due to 1 previous error diff --git a/tests/ui/attributes/extented-attribute-macro-error.stderr b/tests/ui/attributes/extented-attribute-macro-error.stderr index 0fcde9b7c..884f3c7b1 100644 --- a/tests/ui/attributes/extented-attribute-macro-error.stderr +++ b/tests/ui/attributes/extented-attribute-macro-error.stderr @@ -6,5 +6,5 @@ LL | #![doc = include_str!("../not_existing_file.md")] | = note: this error originates in the macro `include_str` (in Nightly builds, run with -Z macro-backtrace for more info) -error: aborting due to previous error +error: aborting due to 1 previous error diff --git a/tests/ui/attributes/invalid-repr.stderr b/tests/ui/attributes/invalid-repr.stderr index 98a6a24b3..681460ad0 100644 --- a/tests/ui/attributes/invalid-repr.stderr +++ b/tests/ui/attributes/invalid-repr.stderr @@ -7,6 +7,6 @@ LL | LL | pub type Foo = i32; | ------------------- not a struct, enum, function, associated function, or union -error: aborting due to previous error +error: aborting due to 1 previous error For more information about this error, try `rustc --explain E0517`. diff --git a/tests/ui/attributes/issue-100631.stderr b/tests/ui/attributes/issue-100631.stderr index caa5351dd..6e8e4f3b4 100644 --- a/tests/ui/attributes/issue-100631.stderr +++ b/tests/ui/attributes/issue-100631.stderr @@ -7,6 +7,6 @@ LL | #[repr(C)] LL | enum Foo {} | -------- zero-variant enum -error: aborting due to previous error +error: aborting due to 1 previous error For more information about this error, try `rustc --explain E0084`. diff --git a/tests/ui/attributes/issue-90873.rs b/tests/ui/attributes/issue-90873.rs index 1411f6174..53339ce7e 100644 --- a/tests/ui/attributes/issue-90873.rs +++ b/tests/ui/attributes/issue-90873.rs @@ -1,9 +1,9 @@ #![u=||{static d=||1;}] -//~^ unexpected expression +//~^ attribute value must be a literal //~| cannot find attribute `u` in this scope //~| missing type for `static` item #![a={impl std::ops::Neg for i8 {}}] -//~^ ERROR unexpected expression +//~^ ERROR attribute value must be a literal //~| ERROR cannot find attribute `a` in this scope //~| ERROR `main` function not found in crate `issue_90873` diff --git a/tests/ui/attributes/issue-90873.stderr b/tests/ui/attributes/issue-90873.stderr index 894ec8341..5a8bbaf8e 100644 --- a/tests/ui/attributes/issue-90873.stderr +++ b/tests/ui/attributes/issue-90873.stderr @@ -1,15 +1,10 @@ -error: unexpected expression: `|| - { - static d: _ = || 1; - }` +error: attribute value must be a literal --> $DIR/issue-90873.rs:1:6 | LL | #![u=||{static d=||1;}] | ^^^^^^^^^^^^^^^^^ -error: unexpected expression: `{ - impl std::ops::Neg for i8 {} - }` +error: attribute value must be a literal --> $DIR/issue-90873.rs:6:6 | LL | #![a={impl std::ops::Neg for i8 {}}] diff --git a/tests/ui/attributes/key-value-expansion-on-mac.rs b/tests/ui/attributes/key-value-expansion-on-mac.rs index c1d68d8cd..ea7cf7c4f 100644 --- a/tests/ui/attributes/key-value-expansion-on-mac.rs +++ b/tests/ui/attributes/key-value-expansion-on-mac.rs @@ -7,8 +7,8 @@ macro_rules! bar { // FIXME?: `bar` here expands before `stringify` has a chance to expand. // `#[rustc_dummy = ...]` is validated and dropped during expansion of `bar`, -// the "unexpected expression" errors comes from the validation. -#[rustc_dummy = stringify!(b)] //~ ERROR unexpected expression: `stringify!(b)` +// the "attribute value must be a literal" error comes from the validation. +#[rustc_dummy = stringify!(b)] //~ ERROR attribute value must be a literal bar!(); fn main() {} diff --git a/tests/ui/attributes/key-value-expansion-on-mac.stderr b/tests/ui/attributes/key-value-expansion-on-mac.stderr index 64ab892d9..260462cfe 100644 --- a/tests/ui/attributes/key-value-expansion-on-mac.stderr +++ b/tests/ui/attributes/key-value-expansion-on-mac.stderr @@ -1,8 +1,8 @@ -error: unexpected expression: `stringify!(b)` +error: attribute value must be a literal --> $DIR/key-value-expansion-on-mac.rs:11:17 | LL | #[rustc_dummy = stringify!(b)] | ^^^^^^^^^^^^^ -error: aborting due to previous error +error: aborting due to 1 previous error diff --git a/tests/ui/attributes/key-value-expansion.rs b/tests/ui/attributes/key-value-expansion.rs index 83d601e5e..3065c1274 100644 --- a/tests/ui/attributes/key-value-expansion.rs +++ b/tests/ui/attributes/key-value-expansion.rs @@ -18,13 +18,13 @@ macro_rules! bug { // Any expressions containing macro call `X` that's more complex than `X` itself. // Parentheses will work. -bug!((column!())); //~ ERROR unexpected expression: `(7u32)` +bug!((column!())); //~ ERROR attribute value must be a literal // Original test case. macro_rules! bug { () => { - bug!("bug" + stringify!(found)); //~ ERROR unexpected expression: `"bug" + "found"` + bug!("bug" + stringify!(found)); //~ ERROR attribute value must be a literal }; ($test:expr) => { #[doc = $test] @@ -46,7 +46,7 @@ macro_rules! doc_comment { macro_rules! some_macro { ($t1: ty) => { doc_comment! {format!("{coor}", coor = stringify!($t1)).as_str()} - //~^ ERROR unexpected expression: `{ + //~^ ERROR attribute value must be a literal }; } diff --git a/tests/ui/attributes/key-value-expansion.stderr b/tests/ui/attributes/key-value-expansion.stderr index aaa8b1695..54d79c5be 100644 --- a/tests/ui/attributes/key-value-expansion.stderr +++ b/tests/ui/attributes/key-value-expansion.stderr @@ -1,10 +1,10 @@ -error: unexpected expression: `(7u32)` +error: attribute value must be a literal --> $DIR/key-value-expansion.rs:21:6 | LL | bug!((column!())); | ^^^^^^^^^^^ -error: unexpected expression: `"bug" + "found"` +error: attribute value must be a literal --> $DIR/key-value-expansion.rs:27:14 | LL | bug!("bug" + stringify!(found)); @@ -15,7 +15,7 @@ LL | bug!(); | = note: this error originates in the macro `bug` (in Nightly builds, run with -Z macro-backtrace for more info) -error: unexpected expression: `{ let res = ::alloc::fmt::format(format_args!("{0}", "u8")); res }.as_str()` +error: attribute value must be a literal --> $DIR/key-value-expansion.rs:48:23 | LL | doc_comment! {format!("{coor}", coor = stringify!($t1)).as_str()} diff --git a/tests/ui/attributes/key-value-non-ascii.stderr b/tests/ui/attributes/key-value-non-ascii.stderr index 23d482de6..cc01bc46e 100644 --- a/tests/ui/attributes/key-value-non-ascii.stderr +++ b/tests/ui/attributes/key-value-non-ascii.stderr @@ -9,5 +9,5 @@ help: if you meant to use the UTF-8 encoding of 'ffi', use \xHH escapes LL | #[rustc_dummy = b"/xEF/xAC/x83.rs"] | ~~~~~~~~~~~~ -error: aborting due to previous error +error: aborting due to 1 previous error diff --git a/tests/ui/attributes/macro_export_on_decl_macro.stderr b/tests/ui/attributes/macro_export_on_decl_macro.stderr index 565e07919..10b86da4f 100644 --- a/tests/ui/attributes/macro_export_on_decl_macro.stderr +++ b/tests/ui/attributes/macro_export_on_decl_macro.stderr @@ -12,5 +12,5 @@ LL | #![deny(unused)] | ^^^^^^ = note: `#[deny(unused_attributes)]` implied by `#[deny(unused)]` -error: aborting due to previous error +error: aborting due to 1 previous error diff --git a/tests/ui/attributes/main-removed-1.stderr b/tests/ui/attributes/main-removed-1.stderr index 2422c5c3b..fda28772e 100644 --- a/tests/ui/attributes/main-removed-1.stderr +++ b/tests/ui/attributes/main-removed-1.stderr @@ -6,5 +6,5 @@ LL | #[main] | = note: `main` is in scope, but it is a function, not an attribute -error: aborting due to previous error +error: aborting due to 1 previous error diff --git a/tests/ui/attributes/no-mangle-closure.stderr b/tests/ui/attributes/no-mangle-closure.stderr index 949eb7051..c18378349 100644 --- a/tests/ui/attributes/no-mangle-closure.stderr +++ b/tests/ui/attributes/no-mangle-closure.stderr @@ -4,5 +4,5 @@ error: `#[no_mangle]` cannot be used on a closure as it has no name LL | (#[no_mangle] || y.0[0])() | ^^^^^^^^^^^^ -error: aborting due to previous error +error: aborting due to 1 previous error diff --git a/tests/ui/attributes/unix_sigpipe/unix_sigpipe-crate.stderr b/tests/ui/attributes/unix_sigpipe/unix_sigpipe-crate.stderr index 225b8e8f3..1666f4a3e 100644 --- a/tests/ui/attributes/unix_sigpipe/unix_sigpipe-crate.stderr +++ b/tests/ui/attributes/unix_sigpipe/unix_sigpipe-crate.stderr @@ -13,5 +13,5 @@ LL - #![unix_sigpipe = "inherit"] LL + #[unix_sigpipe = "inherit"] | -error: aborting due to previous error +error: aborting due to 1 previous error diff --git a/tests/ui/attributes/unix_sigpipe/unix_sigpipe-duplicates.stderr b/tests/ui/attributes/unix_sigpipe/unix_sigpipe-duplicates.stderr index 2362c17a0..931aae96b 100644 --- a/tests/ui/attributes/unix_sigpipe/unix_sigpipe-duplicates.stderr +++ b/tests/ui/attributes/unix_sigpipe/unix_sigpipe-duplicates.stderr @@ -10,5 +10,5 @@ note: attribute also specified here LL | #[unix_sigpipe = "sig_ign"] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^ -error: aborting due to previous error +error: aborting due to 1 previous error diff --git a/tests/ui/attributes/unix_sigpipe/unix_sigpipe-list.stderr b/tests/ui/attributes/unix_sigpipe/unix_sigpipe-list.stderr index 59a87e139..b1d79d7c2 100644 --- a/tests/ui/attributes/unix_sigpipe/unix_sigpipe-list.stderr +++ b/tests/ui/attributes/unix_sigpipe/unix_sigpipe-list.stderr @@ -11,5 +11,5 @@ LL | #[unix_sigpipe = "inherit|sig_ign|sig_dfl"] LL | #[unix_sigpipe] | ~~~~~~~~~~~~~~~ -error: aborting due to previous error +error: aborting due to 1 previous error diff --git a/tests/ui/attributes/unix_sigpipe/unix_sigpipe-non-main-fn.stderr b/tests/ui/attributes/unix_sigpipe/unix_sigpipe-non-main-fn.stderr index c4b81118c..124141b65 100644 --- a/tests/ui/attributes/unix_sigpipe/unix_sigpipe-non-main-fn.stderr +++ b/tests/ui/attributes/unix_sigpipe/unix_sigpipe-non-main-fn.stderr @@ -4,5 +4,5 @@ error: `unix_sigpipe` attribute can only be used on `fn main()` LL | #[unix_sigpipe = "inherit"] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^ -error: aborting due to previous error +error: aborting due to 1 previous error diff --git a/tests/ui/attributes/unix_sigpipe/unix_sigpipe-non-root-main.stderr b/tests/ui/attributes/unix_sigpipe/unix_sigpipe-non-root-main.stderr index a04f605ed..346d83fa6 100644 --- a/tests/ui/attributes/unix_sigpipe/unix_sigpipe-non-root-main.stderr +++ b/tests/ui/attributes/unix_sigpipe/unix_sigpipe-non-root-main.stderr @@ -4,5 +4,5 @@ error: `unix_sigpipe` attribute can only be used on root `fn main()` LL | #[unix_sigpipe = "inherit"] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^ -error: aborting due to previous error +error: aborting due to 1 previous error diff --git a/tests/ui/attributes/unix_sigpipe/unix_sigpipe-start.stderr b/tests/ui/attributes/unix_sigpipe/unix_sigpipe-start.stderr index 2c9ce479b..9f691e396 100644 --- a/tests/ui/attributes/unix_sigpipe/unix_sigpipe-start.stderr +++ b/tests/ui/attributes/unix_sigpipe/unix_sigpipe-start.stderr @@ -4,5 +4,5 @@ error: `unix_sigpipe` attribute can only be used on `fn main()` LL | #[unix_sigpipe = "inherit"] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^ -error: aborting due to previous error +error: aborting due to 1 previous error diff --git a/tests/ui/attributes/unix_sigpipe/unix_sigpipe-struct.stderr b/tests/ui/attributes/unix_sigpipe/unix_sigpipe-struct.stderr index c56ee60bb..d5eec9424 100644 --- a/tests/ui/attributes/unix_sigpipe/unix_sigpipe-struct.stderr +++ b/tests/ui/attributes/unix_sigpipe/unix_sigpipe-struct.stderr @@ -4,5 +4,5 @@ error: `unix_sigpipe` attribute can only be used on `fn main()` LL | #[unix_sigpipe = "inherit"] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^ -error: aborting due to previous error +error: aborting due to 1 previous error diff --git a/tests/ui/attributes/unix_sigpipe/unix_sigpipe-wrong.stderr b/tests/ui/attributes/unix_sigpipe/unix_sigpipe-wrong.stderr index a66e45aa2..d750443e4 100644 --- a/tests/ui/attributes/unix_sigpipe/unix_sigpipe-wrong.stderr +++ b/tests/ui/attributes/unix_sigpipe/unix_sigpipe-wrong.stderr @@ -4,5 +4,5 @@ error: valid values for `#[unix_sigpipe = "..."]` are `inherit`, `sig_ign`, or ` LL | #[unix_sigpipe = "wrong"] | ^^^^^^^^^^^^^^^^^^^^^^^^^ -error: aborting due to previous error +error: aborting due to 1 previous error diff --git a/tests/ui/attributes/unix_sigpipe/unix_sigpipe.stderr b/tests/ui/attributes/unix_sigpipe/unix_sigpipe.stderr index 1b1eda825..b18ec9abc 100644 --- a/tests/ui/attributes/unix_sigpipe/unix_sigpipe.stderr +++ b/tests/ui/attributes/unix_sigpipe/unix_sigpipe.stderr @@ -4,5 +4,5 @@ error: valid values for `#[unix_sigpipe = "..."]` are `inherit`, `sig_ign`, or ` LL | #[unix_sigpipe] | ^^^^^^^^^^^^^^^ -error: aborting due to previous error +error: aborting due to 1 previous error diff --git a/tests/ui/attributes/unused-item-in-attr.rs b/tests/ui/attributes/unused-item-in-attr.rs index 70dcd5413..fda0a5d6a 100644 --- a/tests/ui/attributes/unused-item-in-attr.rs +++ b/tests/ui/attributes/unused-item-in-attr.rs @@ -1,5 +1,5 @@ #[w = { extern crate alloc; }] -//~^ ERROR unexpected expression: `{ +//~^ ERROR attribute value must be a literal //~| ERROR cannot find attribute `w` in this scope fn f() {} diff --git a/tests/ui/attributes/unused-item-in-attr.stderr b/tests/ui/attributes/unused-item-in-attr.stderr index 92a8f5858..84130965d 100644 --- a/tests/ui/attributes/unused-item-in-attr.stderr +++ b/tests/ui/attributes/unused-item-in-attr.stderr @@ -1,6 +1,4 @@ -error: unexpected expression: `{ - extern crate alloc; - }` +error: attribute value must be a literal --> $DIR/unused-item-in-attr.rs:1:7 | LL | #[w = { extern crate alloc; }] diff --git a/tests/ui/attributes/used_with_multi_args.stderr b/tests/ui/attributes/used_with_multi_args.stderr index c93aafcfc..d4417a202 100644 --- a/tests/ui/attributes/used_with_multi_args.stderr +++ b/tests/ui/attributes/used_with_multi_args.stderr @@ -4,5 +4,5 @@ error: expected `used`, `used(compiler)` or `used(linker)` LL | #[used(compiler, linker)] | ^^^^^^^^^^^^^^^^^^^^^^^^^ -error: aborting due to previous error +error: aborting due to 1 previous error |