summaryrefslogtreecommitdiffstats
path: root/tests/ui/typeof/issue-42060.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/typeof/issue-42060.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/typeof/issue-42060.stderr')
-rw-r--r--tests/ui/typeof/issue-42060.stderr32
1 files changed, 32 insertions, 0 deletions
diff --git a/tests/ui/typeof/issue-42060.stderr b/tests/ui/typeof/issue-42060.stderr
new file mode 100644
index 000000000..effcbe4d7
--- /dev/null
+++ b/tests/ui/typeof/issue-42060.stderr
@@ -0,0 +1,32 @@
+error[E0435]: attempt to use a non-constant value in a constant
+ --> $DIR/issue-42060.rs:3:23
+ |
+LL | let thing = ();
+ | --------- help: consider using `const` instead of `let`: `const thing`
+LL | let other: typeof(thing) = thing;
+ | ^^^^^ non-constant value
+
+error[E0435]: attempt to use a non-constant value in a constant
+ --> $DIR/issue-42060.rs:9:13
+ |
+LL | let q = 1;
+ | ----- help: consider using `const` instead of `let`: `const q`
+LL | <typeof(q)>::N
+ | ^ non-constant value
+
+error[E0516]: `typeof` is a reserved keyword but unimplemented
+ --> $DIR/issue-42060.rs:3:16
+ |
+LL | let other: typeof(thing) = thing;
+ | ^^^^^^^^^^^^^ reserved keyword
+
+error[E0516]: `typeof` is a reserved keyword but unimplemented
+ --> $DIR/issue-42060.rs:9:6
+ |
+LL | <typeof(q)>::N
+ | ^^^^^^^^^ reserved keyword
+
+error: aborting due to 4 previous errors
+
+Some errors have detailed explanations: E0435, E0516.
+For more information about an error, try `rustc --explain E0435`.