review comment: wording
This commit is contained in:
parent
0dcdbaec0b
commit
542be6fb6c
4 changed files with 12 additions and 10 deletions
|
|
@ -1340,16 +1340,18 @@ impl<'a, 'tcx> InferCtxt<'a, 'tcx> {
|
|||
err.span_label(
|
||||
*sp,
|
||||
format!(
|
||||
"{}the {} {}{}{}",
|
||||
if count > 1 { "one of " } else { "" },
|
||||
target,
|
||||
key,
|
||||
pluralize!(count),
|
||||
"{}{}{} {}{}",
|
||||
if sp.is_desugaring(DesugaringKind::Async) {
|
||||
" in the `Output` of this `async fn`"
|
||||
"the `Output` of this `async fn`'s "
|
||||
} else if count == 1 {
|
||||
"the "
|
||||
} else {
|
||||
""
|
||||
},
|
||||
if count > 1 { "one of the " } else { "" },
|
||||
target,
|
||||
key,
|
||||
pluralize!(count),
|
||||
),
|
||||
);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@ error[E0308]: mismatched types
|
|||
--> $DIR/dont-suggest-missing-await.rs:14:18
|
||||
|
|
||||
LL | async fn make_u32() -> u32 {
|
||||
| --- the found opaque type in the `Output` of this `async fn`
|
||||
| --- the `Output` of this `async fn`'s found opaque type
|
||||
...
|
||||
LL | take_u32(x)
|
||||
| ^ expected `u32`, found opaque type
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@ error[E0308]: mismatched types
|
|||
--> $DIR/suggest-missing-await-closure.rs:16:18
|
||||
|
|
||||
LL | async fn make_u32() -> u32 {
|
||||
| --- the found opaque type in the `Output` of this `async fn`
|
||||
| --- the `Output` of this `async fn`'s found opaque type
|
||||
...
|
||||
LL | take_u32(x)
|
||||
| ^
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@ error[E0308]: mismatched types
|
|||
--> $DIR/suggest-missing-await.rs:13:14
|
||||
|
|
||||
LL | async fn make_u32() -> u32 {
|
||||
| --- the found opaque type in the `Output` of this `async fn`
|
||||
| --- the `Output` of this `async fn`'s found opaque type
|
||||
...
|
||||
LL | take_u32(x)
|
||||
| ^
|
||||
|
|
@ -17,7 +17,7 @@ error[E0308]: mismatched types
|
|||
--> $DIR/suggest-missing-await.rs:23:5
|
||||
|
|
||||
LL | async fn dummy() {}
|
||||
| - the found opaque type in the `Output` of this `async fn`
|
||||
| - the `Output` of this `async fn`'s found opaque type
|
||||
...
|
||||
LL | dummy()
|
||||
| ^^^^^^^ expected `()`, found opaque type
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue