summaryrefslogtreecommitdiffstats
path: root/tests/ui/issues/issue-78957.stderr
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-17 12:18:58 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-17 12:18:58 +0000
commita4b7ed7a42c716ab9f05e351f003d589124fd55d (patch)
treeb620cd3f223850b28716e474e80c58059dca5dd4 /tests/ui/issues/issue-78957.stderr
parentAdding upstream version 1.67.1+dfsg1. (diff)
downloadrustc-a4b7ed7a42c716ab9f05e351f003d589124fd55d.tar.xz
rustc-a4b7ed7a42c716ab9f05e351f003d589124fd55d.zip
Adding upstream version 1.68.2+dfsg1.upstream/1.68.2+dfsg1
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'tests/ui/issues/issue-78957.stderr')
-rw-r--r--tests/ui/issues/issue-78957.stderr69
1 files changed, 69 insertions, 0 deletions
diff --git a/tests/ui/issues/issue-78957.stderr b/tests/ui/issues/issue-78957.stderr
new file mode 100644
index 000000000..6de22d6bf
--- /dev/null
+++ b/tests/ui/issues/issue-78957.stderr
@@ -0,0 +1,69 @@
+error[E0518]: attribute should be applied to function or closure
+ --> $DIR/issue-78957.rs:5:16
+ |
+LL | pub struct Foo<#[inline] const N: usize>;
+ | ^^^^^^^^^ -------------- not a function or closure
+
+error: attribute should be applied to a function definition
+ --> $DIR/issue-78957.rs:7:16
+ |
+LL | pub struct Bar<#[cold] const N: usize>;
+ | ^^^^^^^ -------------- not a function definition
+ |
+ = warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release!
+note: the lint level is defined here
+ --> $DIR/issue-78957.rs:1:9
+ |
+LL | #![deny(unused_attributes)]
+ | ^^^^^^^^^^^^^^^^^
+
+error[E0517]: attribute should be applied to a struct, enum, or union
+ --> $DIR/issue-78957.rs:10:23
+ |
+LL | pub struct Baz<#[repr(C)] const N: usize>;
+ | ^ -------------- not a struct, enum, or union
+
+error[E0518]: attribute should be applied to function or closure
+ --> $DIR/issue-78957.rs:13:17
+ |
+LL | pub struct Foo2<#[inline] 'a>(PhantomData<&'a ()>);
+ | ^^^^^^^^^ -- not a function or closure
+
+error: attribute should be applied to a function definition
+ --> $DIR/issue-78957.rs:15:17
+ |
+LL | pub struct Bar2<#[cold] 'a>(PhantomData<&'a ()>);
+ | ^^^^^^^ -- not a function definition
+ |
+ = warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release!
+
+error[E0517]: attribute should be applied to a struct, enum, or union
+ --> $DIR/issue-78957.rs:18:24
+ |
+LL | pub struct Baz2<#[repr(C)] 'a>(PhantomData<&'a ()>);
+ | ^ -- not a struct, enum, or union
+
+error[E0518]: attribute should be applied to function or closure
+ --> $DIR/issue-78957.rs:21:17
+ |
+LL | pub struct Foo3<#[inline] T>(PhantomData<T>);
+ | ^^^^^^^^^ - not a function or closure
+
+error: attribute should be applied to a function definition
+ --> $DIR/issue-78957.rs:23:17
+ |
+LL | pub struct Bar3<#[cold] T>(PhantomData<T>);
+ | ^^^^^^^ - not a function definition
+ |
+ = warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release!
+
+error[E0517]: attribute should be applied to a struct, enum, or union
+ --> $DIR/issue-78957.rs:26:24
+ |
+LL | pub struct Baz3<#[repr(C)] T>(PhantomData<T>);
+ | ^ - not a struct, enum, or union
+
+error: aborting due to 9 previous errors
+
+Some errors have detailed explanations: E0517, E0518.
+For more information about an error, try `rustc --explain E0517`.