review comment: move test
This commit is contained in:
@@ -4,8 +4,9 @@
|
||||
async fn do_the_thing() -> u8 {
|
||||
8
|
||||
}
|
||||
|
||||
fn main() {
|
||||
// #63398: point at the enclosing scope and not the previously seen closure
|
||||
fn main() { //~ NOTE this is not `async`
|
||||
let x = move || {};
|
||||
let y = do_the_thing().await; //~ ERROR `await` is only allowed inside `async` functions
|
||||
//~^ NOTE only allowed inside `async` functions and blocks
|
||||
}
|
||||
@@ -1,5 +1,5 @@
|
||||
error[E0728]: `await` is only allowed inside `async` functions and blocks
|
||||
--> $DIR/issue-63398.rs:10:13
|
||||
--> $DIR/non-async-enclosing-span.rs:10:13
|
||||
|
|
||||
LL | fn main() {
|
||||
| ---- this is not `async`
|
||||
Reference in New Issue
Block a user