diff options
| author | Niko Matsakis <niko@alum.mit.edu> | 2019-10-02 14:39:44 -0400 |
|---|---|---|
| committer | Niko Matsakis <niko@alum.mit.edu> | 2019-10-02 14:39:44 -0400 |
| commit | 3f277e1a66f0e8de9cc46c9a886b4ad0f4582944 (patch) | |
| tree | ea49fd5bc0b455e738d3b6a72f3b8a83d31f2557 | |
| parent | 5fea1d279bdc7863f38a7bf2b58ecf66c18ef6d7 (diff) | |
| download | rust-3f277e1a66f0e8de9cc46c9a886b4ad0f4582944.tar.gz rust-3f277e1a66f0e8de9cc46c9a886b4ad0f4582944.zip | |
s/`async` fn/`async fn`/
| -rw-r--r-- | src/librustc/hir/mod.rs | 2 | ||||
| -rw-r--r-- | src/test/ui/async-await/async-error-span.rs | 2 | ||||
| -rw-r--r-- | src/test/ui/async-await/async-error-span.stderr | 4 | ||||
| -rw-r--r-- | src/test/ui/async-await/unresolved_type_param.rs | 4 | ||||
| -rw-r--r-- | src/test/ui/async-await/unresolved_type_param.stderr | 4 |
5 files changed, 8 insertions, 8 deletions
diff --git a/src/librustc/hir/mod.rs b/src/librustc/hir/mod.rs index ec44c92bd33..1a84889513d 100644 --- a/src/librustc/hir/mod.rs +++ b/src/librustc/hir/mod.rs @@ -1404,7 +1404,7 @@ impl fmt::Display for AsyncGeneratorKind { f.write_str(match self { AsyncGeneratorKind::Block => "`async` block", AsyncGeneratorKind::Closure => "`async` closure body", - AsyncGeneratorKind::Fn => "`async` fn body", + AsyncGeneratorKind::Fn => "`async fn` body", }) } } diff --git a/src/test/ui/async-await/async-error-span.rs b/src/test/ui/async-await/async-error-span.rs index 0559e627643..28132c9789c 100644 --- a/src/test/ui/async-await/async-error-span.rs +++ b/src/test/ui/async-await/async-error-span.rs @@ -9,7 +9,7 @@ fn get_future() -> impl Future<Output = ()> { } async fn foo() { - let a; //~ ERROR type inside `async` fn body must be known in this context + let a; //~ ERROR type inside `async fn` body must be known in this context get_future().await; } diff --git a/src/test/ui/async-await/async-error-span.stderr b/src/test/ui/async-await/async-error-span.stderr index 384029f3aa5..b551b99587d 100644 --- a/src/test/ui/async-await/async-error-span.stderr +++ b/src/test/ui/async-await/async-error-span.stderr @@ -1,10 +1,10 @@ -error[E0698]: type inside `async` fn body must be known in this context +error[E0698]: type inside `async fn` body must be known in this context --> $DIR/async-error-span.rs:12:9 | LL | let a; | ^ cannot infer type | -note: the type is part of the `async` fn body because of this `await` +note: the type is part of the `async fn` body because of this `await` --> $DIR/async-error-span.rs:13:5 | LL | get_future().await; diff --git a/src/test/ui/async-await/unresolved_type_param.rs b/src/test/ui/async-await/unresolved_type_param.rs index 8d035d038ab..2876f9fea0e 100644 --- a/src/test/ui/async-await/unresolved_type_param.rs +++ b/src/test/ui/async-await/unresolved_type_param.rs @@ -7,9 +7,9 @@ async fn bar<T>() -> () {} async fn foo() { bar().await; - //~^ ERROR type inside `async` fn body must be known in this context + //~^ ERROR type inside `async fn` body must be known in this context //~| NOTE cannot infer type for `T` - //~| NOTE the type is part of the `async` fn body because of this `await` + //~| NOTE the type is part of the `async fn` body because of this `await` //~| NOTE in this expansion of desugaring of `await` } fn main() {} diff --git a/src/test/ui/async-await/unresolved_type_param.stderr b/src/test/ui/async-await/unresolved_type_param.stderr index 652f15cffe2..c7866fc7744 100644 --- a/src/test/ui/async-await/unresolved_type_param.stderr +++ b/src/test/ui/async-await/unresolved_type_param.stderr @@ -1,10 +1,10 @@ -error[E0698]: type inside `async` fn body must be known in this context +error[E0698]: type inside `async fn` body must be known in this context --> $DIR/unresolved_type_param.rs:9:5 | LL | bar().await; | ^^^ cannot infer type for `T` | -note: the type is part of the `async` fn body because of this `await` +note: the type is part of the `async fn` body because of this `await` --> $DIR/unresolved_type_param.rs:9:5 | LL | bar().await; |
