summaryrefslogtreecommitdiffstats
path: root/tests/ui/malformed/malformed-derive-entry.stderr
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-17 12:19:13 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-17 12:19:13 +0000
commit218caa410aa38c29984be31a5229b9fa717560ee (patch)
treec54bd55eeb6e4c508940a30e94c0032fbd45d677 /tests/ui/malformed/malformed-derive-entry.stderr
parentReleasing progress-linux version 1.67.1+dfsg1-1~progress7.99u1. (diff)
downloadrustc-218caa410aa38c29984be31a5229b9fa717560ee.tar.xz
rustc-218caa410aa38c29984be31a5229b9fa717560ee.zip
Merging upstream version 1.68.2+dfsg1.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'tests/ui/malformed/malformed-derive-entry.stderr')
-rw-r--r--tests/ui/malformed/malformed-derive-entry.stderr49
1 files changed, 49 insertions, 0 deletions
diff --git a/tests/ui/malformed/malformed-derive-entry.stderr b/tests/ui/malformed/malformed-derive-entry.stderr
new file mode 100644
index 000000000..6ff6fbabb
--- /dev/null
+++ b/tests/ui/malformed/malformed-derive-entry.stderr
@@ -0,0 +1,49 @@
+error: traits in `#[derive(...)]` don't accept arguments
+ --> $DIR/malformed-derive-entry.rs:1:14
+ |
+LL | #[derive(Copy(Bad))]
+ | ^^^^^ help: remove the arguments
+
+error: traits in `#[derive(...)]` don't accept values
+ --> $DIR/malformed-derive-entry.rs:6:14
+ |
+LL | #[derive(Copy="bad")]
+ | ^^^^^^ help: remove the value
+
+error: malformed `derive` attribute input
+ --> $DIR/malformed-derive-entry.rs:11:1
+ |
+LL | #[derive]
+ | ^^^^^^^^^ help: must be of the form: `#[derive(Trait1, Trait2, ...)]`
+
+error[E0277]: the trait bound `Test1: Clone` is not satisfied
+ --> $DIR/malformed-derive-entry.rs:1:10
+ |
+LL | #[derive(Copy(Bad))]
+ | ^^^^ the trait `Clone` is not implemented for `Test1`
+ |
+note: required by a bound in `Copy`
+ --> $SRC_DIR/core/src/marker.rs:LL:COL
+ = note: this error originates in the derive macro `Copy` (in Nightly builds, run with -Z macro-backtrace for more info)
+help: consider annotating `Test1` with `#[derive(Clone)]`
+ |
+LL | #[derive(Clone)]
+ |
+
+error[E0277]: the trait bound `Test2: Clone` is not satisfied
+ --> $DIR/malformed-derive-entry.rs:6:10
+ |
+LL | #[derive(Copy="bad")]
+ | ^^^^ the trait `Clone` is not implemented for `Test2`
+ |
+note: required by a bound in `Copy`
+ --> $SRC_DIR/core/src/marker.rs:LL:COL
+ = note: this error originates in the derive macro `Copy` (in Nightly builds, run with -Z macro-backtrace for more info)
+help: consider annotating `Test2` with `#[derive(Clone)]`
+ |
+LL | #[derive(Clone)]
+ |
+
+error: aborting due to 5 previous errors
+
+For more information about this error, try `rustc --explain E0277`.