Clean up E0728 explanation

This commit is contained in:
Guillaume Gomez 2020-07-24 17:43:12 +02:00
parent 9e92106d45
commit 4031645691

View File

@ -1,6 +1,6 @@
[`await`] has been used outside [`async`] function or block.
[`await`] has been used outside [`async`] function or [`async`] block.
Erroneous code examples:
Erroneous code example:
```edition2018,compile_fail,E0728
# use std::pin::Pin;
@ -33,7 +33,7 @@ fn foo() {
[`await`] is used to suspend the current computation until the given
future is ready to produce a value. So it is legal only within
an [`async`] context, like an `async fn` or an `async` block.
an [`async`] context, like an `async` function or an `async` block.
```edition2018
# use std::pin::Pin;