summaryrefslogtreecommitdiffstats
path: root/tests/ui/liveness/liveness-assign/liveness-assign-imm-local-in-loop.stderr
diff options
context:
space:
mode:
Diffstat (limited to 'tests/ui/liveness/liveness-assign/liveness-assign-imm-local-in-loop.stderr')
-rw-r--r--tests/ui/liveness/liveness-assign/liveness-assign-imm-local-in-loop.stderr12
1 files changed, 12 insertions, 0 deletions
diff --git a/tests/ui/liveness/liveness-assign/liveness-assign-imm-local-in-loop.stderr b/tests/ui/liveness/liveness-assign/liveness-assign-imm-local-in-loop.stderr
new file mode 100644
index 000000000..66cdce7da
--- /dev/null
+++ b/tests/ui/liveness/liveness-assign/liveness-assign-imm-local-in-loop.stderr
@@ -0,0 +1,12 @@
+error[E0384]: cannot assign twice to immutable variable `v`
+ --> $DIR/liveness-assign-imm-local-in-loop.rs:6:9
+ |
+LL | let v: isize;
+ | - help: consider making this binding mutable: `mut v`
+...
+LL | v = 1;
+ | ^^^^^ cannot assign twice to immutable variable
+
+error: aborting due to previous error
+
+For more information about this error, try `rustc --explain E0384`.