summaryrefslogtreecommitdiffstats
path: root/tests/ui/suggestions/if-then-neeing-semi.rs
diff options
context:
space:
mode:
Diffstat (limited to 'tests/ui/suggestions/if-then-neeing-semi.rs')
-rw-r--r--tests/ui/suggestions/if-then-neeing-semi.rs26
1 files changed, 8 insertions, 18 deletions
diff --git a/tests/ui/suggestions/if-then-neeing-semi.rs b/tests/ui/suggestions/if-then-neeing-semi.rs
index b487f013d..a4eefb415 100644
--- a/tests/ui/suggestions/if-then-neeing-semi.rs
+++ b/tests/ui/suggestions/if-then-neeing-semi.rs
@@ -15,18 +15,9 @@ fn extra_semicolon() {
};
}
-async fn async_dummy() {} //~ NOTE checked the `Output` of this `async fn`, found opaque type
-//~| NOTE while checking the return type of the `async fn`
-//~| NOTE in this expansion of desugaring of `async` block or function
-//~| NOTE checked the `Output` of this `async fn`, expected opaque type
-//~| NOTE while checking the return type of the `async fn`
-//~| NOTE in this expansion of desugaring of `async` block or function
-async fn async_dummy2() {} //~ NOTE checked the `Output` of this `async fn`, found opaque type
-//~| NOTE checked the `Output` of this `async fn`, found opaque type
-//~| NOTE while checking the return type of the `async fn`
-//~| NOTE in this expansion of desugaring of `async` block or function
-//~| NOTE while checking the return type of the `async fn`
-//~| NOTE in this expansion of desugaring of `async` block or function
+async fn async_dummy() {}
+
+async fn async_dummy2() {}
async fn async_extra_semicolon_same() {
let _ = if true {
@@ -35,8 +26,8 @@ async fn async_extra_semicolon_same() {
//~^ HELP consider removing this semicolon
} else {
async_dummy() //~ ERROR `if` and `else` have incompatible types
- //~^ NOTE expected `()`, found opaque type
- //~| NOTE expected unit type `()`
+ //~^ NOTE expected `()`, found future
+ //~| NOTE calling an async function returns a future
//~| HELP consider `await`ing on the `Future`
};
}
@@ -48,8 +39,8 @@ async fn async_extra_semicolon_different() {
//~^ HELP consider removing this semicolon
} else {
async_dummy2() //~ ERROR `if` and `else` have incompatible types
- //~^ NOTE expected `()`, found opaque type
- //~| NOTE expected unit type `()`
+ //~^ NOTE expected `()`, found future
+ //~| NOTE calling an async function returns a future
//~| HELP consider `await`ing on the `Future`
};
}
@@ -61,8 +52,7 @@ async fn async_different_futures() {
//~| HELP consider `await`ing on both `Future`s
} else {
async_dummy2() //~ ERROR `if` and `else` have incompatible types
- //~^ NOTE expected opaque type, found a different opaque type
- //~| NOTE expected opaque type `impl Future<Output = ()>`
+ //~^ NOTE expected future, found a different future
//~| NOTE distinct uses of `impl Trait` result in different opaque types
};
}