os-rust/src/test/ui/suggestions/issue-72766.stderr

21 lines
746 B
Text
Raw Normal View History

error[E0277]: the `?` operator can only be applied to values that implement `Try`
2020-05-30 18:48:54 +09:00
--> $DIR/issue-72766.rs:14:5
|
LL | SadGirl {}.call()?;
2020-10-21 14:25:09 -07:00
| ^^^^^^^^^^^^^^^^^^ the `?` operator cannot be applied to type `impl Future`
2020-05-30 18:48:54 +09:00
|
= help: the trait `Try` is not implemented for `impl Future`
note: required by `branch`
--> $SRC_DIR/core/src/ops/try_trait.rs:LL:COL
|
LL | fn branch(self) -> ControlFlow<Self::Residual, Self::Output>;
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
2020-10-21 14:25:09 -07:00
help: consider `await`ing on the `Future`
|
LL | SadGirl {}.call().await?;
| ^^^^^^
2020-05-30 18:48:54 +09:00
error: aborting due to previous error
For more information about this error, try `rustc --explain E0277`.