diff --git a/compiler/rustc_infer/src/infer/error_reporting/mod.rs b/compiler/rustc_infer/src/infer/error_reporting/mod.rs index d1d6cb43fc74c..fa3ee97293f22 100644 --- a/compiler/rustc_infer/src/infer/error_reporting/mod.rs +++ b/compiler/rustc_infer/src/infer/error_reporting/mod.rs @@ -1490,7 +1490,7 @@ impl<'a, 'tcx> InferCtxt<'a, 'tcx> { format!( "{}{}{} {}{}", if sp.is_desugaring(DesugaringKind::Async) { - "the `Output` of this `async fn`'s " + "checked the return type of this `async fn`, " } else if count == 1 { "the " } else { diff --git a/src/test/ui/async-await/dont-suggest-missing-await.stderr b/src/test/ui/async-await/dont-suggest-missing-await.stderr index 14e72c2b1e7e2..1cf1afb6d3646 100644 --- a/src/test/ui/async-await/dont-suggest-missing-await.stderr +++ b/src/test/ui/async-await/dont-suggest-missing-await.stderr @@ -2,7 +2,7 @@ error[E0308]: mismatched types --> $DIR/dont-suggest-missing-await.rs:14:18 | LL | async fn make_u32() -> u32 { - | --- the `Output` of this `async fn`'s found opaque type + | --- checked the return type of this `async fn`, found opaque type ... LL | take_u32(x) | ^ expected `u32`, found opaque type diff --git a/src/test/ui/async-await/issue-61076.stderr b/src/test/ui/async-await/issue-61076.stderr index db6dc3ea00a8d..d3eaeb7101a3b 100644 --- a/src/test/ui/async-await/issue-61076.stderr +++ b/src/test/ui/async-await/issue-61076.stderr @@ -61,7 +61,7 @@ error[E0308]: mismatched types --> $DIR/issue-61076.rs:92:9 | LL | async fn tuple() -> Tuple { - | ----- the `Output` of this `async fn`'s expected opaque type + | ----- checked the return type of this `async fn`, expected opaque type ... LL | Tuple(_) => {} | ^^^^^^^^ expected opaque type, found struct `Tuple` diff --git a/src/test/ui/async-await/suggest-missing-await-closure.stderr b/src/test/ui/async-await/suggest-missing-await-closure.stderr index 2151057aa7fc0..93f5d2e224ce6 100644 --- a/src/test/ui/async-await/suggest-missing-await-closure.stderr +++ b/src/test/ui/async-await/suggest-missing-await-closure.stderr @@ -2,7 +2,7 @@ error[E0308]: mismatched types --> $DIR/suggest-missing-await-closure.rs:16:18 | LL | async fn make_u32() -> u32 { - | --- the `Output` of this `async fn`'s found opaque type + | --- checked the return type of this `async fn`, found opaque type ... LL | take_u32(x) | ^ expected `u32`, found opaque type diff --git a/src/test/ui/async-await/suggest-missing-await.stderr b/src/test/ui/async-await/suggest-missing-await.stderr index 46615dae7e2ba..1c6245265c818 100644 --- a/src/test/ui/async-await/suggest-missing-await.stderr +++ b/src/test/ui/async-await/suggest-missing-await.stderr @@ -2,7 +2,7 @@ error[E0308]: mismatched types --> $DIR/suggest-missing-await.rs:12:14 | LL | async fn make_u32() -> u32 { - | --- the `Output` of this `async fn`'s found opaque type + | --- checked the return type of this `async fn`, found opaque type ... LL | take_u32(x) | ^ expected `u32`, found opaque type @@ -18,7 +18,7 @@ error[E0308]: mismatched types --> $DIR/suggest-missing-await.rs:22:5 | LL | async fn dummy() {} - | - the `Output` of this `async fn`'s found opaque type + | - checked the return type of this `async fn`, found opaque type ... LL | dummy() | ^^^^^^^ expected `()`, found opaque type diff --git a/src/test/ui/parser/fn-header-semantic-fail.stderr b/src/test/ui/parser/fn-header-semantic-fail.stderr index 2f11f95bf4a7f..a2806dce15e68 100644 --- a/src/test/ui/parser/fn-header-semantic-fail.stderr +++ b/src/test/ui/parser/fn-header-semantic-fail.stderr @@ -189,7 +189,7 @@ LL | async fn ft1(); LL | async fn ft1() {} | ^ | | - | the `Output` of this `async fn`'s found opaque type + | checked the return type of this `async fn`, found opaque type | expected `()`, found opaque type | = note: expected fn pointer `fn()` @@ -204,7 +204,7 @@ LL | const async unsafe extern "C" fn ft5(); LL | const async unsafe extern "C" fn ft5() {} | ^ | | - | the `Output` of this `async fn`'s found opaque type + | checked the return type of this `async fn`, found opaque type | expected `()`, found opaque type | = note: expected fn pointer `unsafe extern "C" fn()` diff --git a/src/test/ui/resolve/issue-70736-async-fn-no-body-def-collector.stderr b/src/test/ui/resolve/issue-70736-async-fn-no-body-def-collector.stderr index 9b59e41501102..447c4ee5095e8 100644 --- a/src/test/ui/resolve/issue-70736-async-fn-no-body-def-collector.stderr +++ b/src/test/ui/resolve/issue-70736-async-fn-no-body-def-collector.stderr @@ -53,7 +53,7 @@ LL | async fn associated(); LL | async fn associated(); | ^ | | - | the `Output` of this `async fn`'s found opaque type + | checked the return type of this `async fn`, found opaque type | expected `()`, found opaque type | = note: expected fn pointer `fn()` diff --git a/src/test/ui/suggestions/match-prev-arm-needing-semi.stderr b/src/test/ui/suggestions/match-prev-arm-needing-semi.stderr index e9803a78f94b3..f6d0041157edc 100644 --- a/src/test/ui/suggestions/match-prev-arm-needing-semi.stderr +++ b/src/test/ui/suggestions/match-prev-arm-needing-semi.stderr @@ -2,7 +2,7 @@ error[E0308]: `match` arms have incompatible types --> $DIR/match-prev-arm-needing-semi.rs:26:18 | LL | async fn async_dummy() {} - | - the `Output` of this `async fn`'s found opaque type + | - checked the return type of this `async fn`, found opaque type ... LL | let _ = match true { | _____________- @@ -36,7 +36,7 @@ error[E0308]: `match` arms have incompatible types --> $DIR/match-prev-arm-needing-semi.rs:39:18 | LL | async fn async_dummy2() {} - | - the `Output` of this `async fn`'s found opaque type + | - checked the return type of this `async fn`, found opaque type ... LL | let _ = match true { | _____________- @@ -70,7 +70,7 @@ error[E0308]: `match` arms have incompatible types --> $DIR/match-prev-arm-needing-semi.rs:50:18 | LL | async fn async_dummy2() {} - | - the `Output` of this `async fn`'s found opaque type + | - checked the return type of this `async fn`, found opaque type ... LL | let _ = match true { | _____________-