Sign in
android
/
toolchain
/
rustc
/
bc2a45aebf2f3f158c878db02ee23d906d1269df
/
.
/
src
/
test
/
ui
/
async-await
/
issues
/
issue-51751.rs
blob: 7afd7ecc826499b5b8a73738dfe771fb5c09566e [
file
] [
log
] [
blame
]
// edition:2018
#![
feature
(
async_await
)]
async
fn
inc
(
limit
:
i64
)
->
i64
{
limit
+
1
}
fn
main
()
{
let
result
=
inc
(
10000
);
let
finished
=
result
.
await
;
//~^ ERROR `await` is only allowed inside `async` functions and blocks
}