mirror of
https://github.com/rust-lang/rust.git
synced 2025-06-07 12:48:30 +00:00
review comment: move test
This commit is contained in:
parent
13fd4666b0
commit
25d507f497
@ -4,8 +4,9 @@
|
|||||||
async fn do_the_thing() -> u8 {
|
async fn do_the_thing() -> u8 {
|
||||||
8
|
8
|
||||||
}
|
}
|
||||||
|
// #63398: point at the enclosing scope and not the previously seen closure
|
||||||
fn main() {
|
fn main() { //~ NOTE this is not `async`
|
||||||
let x = move || {};
|
let x = move || {};
|
||||||
let y = do_the_thing().await; //~ ERROR `await` is only allowed inside `async` functions
|
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
|
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() {
|
LL | fn main() {
|
||||||
| ---- this is not `async`
|
| ---- this is not `async`
|
Loading…
Reference in New Issue
Block a user