review comment: change wording of suggestion
This commit is contained in:
parent
64dea33a3d
commit
1a7f2d5cd9
4 changed files with 4 additions and 4 deletions
|
@ -896,7 +896,7 @@ impl<'a, 'tcx> InferCtxtExt<'tcx> for InferCtxt<'a, 'tcx> {
|
|||
// it is from the local crate.
|
||||
err.span_suggestion_verbose(
|
||||
expr.span.shrink_to_hi().with_hi(span.hi()),
|
||||
"do not `.await` the expression",
|
||||
"remove the `.await`",
|
||||
String::new(),
|
||||
Applicability::MachineApplicable,
|
||||
);
|
||||
|
|
|
@ -27,7 +27,7 @@ LL | [1; ().await];
|
|||
= help: the trait `Future` is not implemented for `()`
|
||||
= note: () must be a future or must implement `IntoFuture` to be awaited
|
||||
= note: required because of the requirements on the impl of `IntoFuture` for `()`
|
||||
help: do not `.await` the expression
|
||||
help: remove the `.await`
|
||||
|
|
||||
LL - [1; ().await];
|
||||
LL + [1; ()];
|
||||
|
|
|
@ -33,7 +33,7 @@ LL | (|_| 2333).await;
|
|||
= help: the trait `Future` is not implemented for `[closure@$DIR/issue-62009-1.rs:12:5: 12:15]`
|
||||
= note: [closure@$DIR/issue-62009-1.rs:12:5: 12:15] must be a future or must implement `IntoFuture` to be awaited
|
||||
= note: required because of the requirements on the impl of `IntoFuture` for `[closure@$DIR/issue-62009-1.rs:12:5: 12:15]`
|
||||
help: do not `.await` the expression
|
||||
help: remove the `.await`
|
||||
|
|
||||
LL - (|_| 2333).await;
|
||||
LL + (|_| 2333);
|
||||
|
|
|
@ -9,7 +9,7 @@ LL | boo().await;
|
|||
= help: the trait `Future` is not implemented for `()`
|
||||
= note: () must be a future or must implement `IntoFuture` to be awaited
|
||||
= note: required because of the requirements on the impl of `IntoFuture` for `()`
|
||||
help: do not `.await` the expression
|
||||
help: remove the `.await`
|
||||
|
|
||||
LL - boo().await;
|
||||
LL + boo();
|
||||
|
|
Loading…
Add table
Reference in a new issue