diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-06-07 05:48:42 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-06-07 05:48:42 +0000 |
commit | cec1877e180393eba0f6ddb0cf97bf3a791631c7 (patch) | |
tree | 47b4dac2a9dd9a40c30c251b4d4a72d7ccf77e9f /tests/ui/try-trait | |
parent | Adding debian version 1.74.1+dfsg1-1. (diff) | |
download | rustc-cec1877e180393eba0f6ddb0cf97bf3a791631c7.tar.xz rustc-cec1877e180393eba0f6ddb0cf97bf3a791631c7.zip |
Merging upstream version 1.75.0+dfsg1.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'tests/ui/try-trait')
-rw-r--r-- | tests/ui/try-trait/bad-interconversion.stderr | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/tests/ui/try-trait/bad-interconversion.stderr b/tests/ui/try-trait/bad-interconversion.stderr index 7eb392faa..d8b9431be 100644 --- a/tests/ui/try-trait/bad-interconversion.stderr +++ b/tests/ui/try-trait/bad-interconversion.stderr @@ -73,7 +73,8 @@ LL | ControlFlow::Continue(Err("hello")?) | ^ this `?` produces `Result<Infallible, &str>`, which is incompatible with `ControlFlow<String>` | = help: the trait `FromResidual<Result<Infallible, &str>>` is not implemented for `ControlFlow<String>` - = help: the trait `FromResidual` is implemented for `ControlFlow<B, C>` + = help: the trait `FromResidual<ControlFlow<String, Infallible>>` is implemented for `ControlFlow<String>` + = help: for that trait implementation, expected `ControlFlow<String, Infallible>`, found `Result<Infallible, &str>` error[E0277]: the `?` operator can only be used on `ControlFlow`s in a function that returns `ControlFlow` --> $DIR/bad-interconversion.rs:37:12 @@ -84,7 +85,8 @@ LL | Some(3)?; | ^ this `?` produces `Option<Infallible>`, which is incompatible with `ControlFlow<u64>` | = help: the trait `FromResidual<Option<Infallible>>` is not implemented for `ControlFlow<u64>` - = help: the trait `FromResidual` is implemented for `ControlFlow<B, C>` + = help: the trait `FromResidual<ControlFlow<u64, Infallible>>` is implemented for `ControlFlow<u64>` + = help: for that trait implementation, expected `ControlFlow<u64, Infallible>`, found `Option<Infallible>` error[E0277]: the `?` operator in a function that returns `ControlFlow<B, _>` can only be used on other `ControlFlow<B, _>`s (with the same Break type) --> $DIR/bad-interconversion.rs:43:29 @@ -96,7 +98,8 @@ LL | ControlFlow::Break(4_u8)?; | = help: the trait `FromResidual<ControlFlow<u8, Infallible>>` is not implemented for `ControlFlow<i64>` = note: unlike `Result`, there's no `From`-conversion performed for `ControlFlow` - = help: the trait `FromResidual` is implemented for `ControlFlow<B, C>` + = help: the trait `FromResidual<ControlFlow<i64, Infallible>>` is implemented for `ControlFlow<i64>` + = help: for that trait implementation, expected `i64`, found `u8` error: aborting due to 8 previous errors |