summaryrefslogtreecommitdiffstats
path: root/tests/ui/suggestions/mut-ref-reassignment.stderr
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-17 12:19:41 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-17 12:19:41 +0000
commit4f9fe856a25ab29345b90e7725509e9ee38a37be (patch)
treee4ffd8a9374cae7b21f7cbfb352927e0e074aff6 /tests/ui/suggestions/mut-ref-reassignment.stderr
parentAdding upstream version 1.68.2+dfsg1. (diff)
downloadrustc-upstream/1.69.0+dfsg1.tar.xz
rustc-upstream/1.69.0+dfsg1.zip
Adding upstream version 1.69.0+dfsg1.upstream/1.69.0+dfsg1
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to '')
-rw-r--r--tests/ui/suggestions/mut-ref-reassignment.stderr8
1 files changed, 4 insertions, 4 deletions
diff --git a/tests/ui/suggestions/mut-ref-reassignment.stderr b/tests/ui/suggestions/mut-ref-reassignment.stderr
index b3cb6dd06..b86a04c7c 100644
--- a/tests/ui/suggestions/mut-ref-reassignment.stderr
+++ b/tests/ui/suggestions/mut-ref-reassignment.stderr
@@ -4,7 +4,7 @@ error[E0308]: mismatched types
LL | fn suggestion(opt: &mut Option<String>) {
| ------------------- expected due to this parameter type
LL | opt = None;
- | ^^^^ expected mutable reference, found enum `Option`
+ | ^^^^ expected `&mut Option<String>`, found `Option<_>`
|
= note: expected mutable reference `&mut Option<String>`
found enum `Option<_>`
@@ -19,7 +19,7 @@ error[E0308]: mismatched types
LL | fn no_suggestion(opt: &mut Result<String, ()>) {
| ----------------------- expected due to this parameter type
LL | opt = None
- | ^^^^ expected mutable reference, found enum `Option`
+ | ^^^^ expected `&mut Result<String, ()>`, found `Option<_>`
|
= note: expected mutable reference `&mut Result<String, ()>`
found enum `Option<_>`
@@ -30,7 +30,7 @@ error[E0308]: mismatched types
LL | fn suggestion2(opt: &mut Option<String>) {
| ------------------- expected due to this parameter type
LL | opt = Some(String::new())
- | ^^^^^^^^^^^^^^^^^^^ expected mutable reference, found enum `Option`
+ | ^^^^^^^^^^^^^^^^^^^ expected `&mut Option<String>`, found `Option<String>`
|
= note: expected mutable reference `&mut Option<String>`
found enum `Option<String>`
@@ -45,7 +45,7 @@ error[E0308]: mismatched types
LL | fn no_suggestion2(opt: &mut Option<String>) {
| ------------------- expected due to this parameter type
LL | opt = Some(42)
- | ^^^^^^^^ expected mutable reference, found enum `Option`
+ | ^^^^^^^^ expected `&mut Option<String>`, found `Option<{integer}>`
|
= note: expected mutable reference `&mut Option<String>`
found enum `Option<{integer}>`