Skip to content

Commit

Permalink
review comment: move test
Browse files Browse the repository at this point in the history
  • Loading branch information
estebank committed Aug 13, 2019
1 parent 13fd466 commit 25d507f
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
Expand Up @@ -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`
Expand Down

0 comments on commit 25d507f

Please sign in to comment.