about summary refs log tree commit diff
path: root/tests/ui/async-await/async-closures
diff options
context:
space:
mode:
Diffstat (limited to 'tests/ui/async-await/async-closures')
-rw-r--r--tests/ui/async-await/async-closures/arg-mismatch.stderr5
-rw-r--r--tests/ui/async-await/async-closures/fn-exception-target-features.rs9
-rw-r--r--tests/ui/async-await/async-closures/fn-exception-target-features.stderr4
3 files changed, 9 insertions, 9 deletions
diff --git a/tests/ui/async-await/async-closures/arg-mismatch.stderr b/tests/ui/async-await/async-closures/arg-mismatch.stderr
index 5c8e6650293..8c11fa15776 100644
--- a/tests/ui/async-await/async-closures/arg-mismatch.stderr
+++ b/tests/ui/async-await/async-closures/arg-mismatch.stderr
@@ -13,8 +13,9 @@ LL |         let c = async |x| {};
    |                        ^
 help: change the type of the numeric literal from `usize` to `i32`
    |
-LL |         c(2i32).await;
-   |            ~~~
+LL -         c(2usize).await;
+LL +         c(2i32).await;
+   |
 
 error: aborting due to 1 previous error
 
diff --git a/tests/ui/async-await/async-closures/fn-exception-target-features.rs b/tests/ui/async-await/async-closures/fn-exception-target-features.rs
index 82fc776fd2c..66cc4139770 100644
--- a/tests/ui/async-await/async-closures/fn-exception-target-features.rs
+++ b/tests/ui/async-await/async-closures/fn-exception-target-features.rs
@@ -1,14 +1,13 @@
 //@ edition: 2021
 //@ only-x86_64
 
-#![feature(target_feature_11)]
-// `target_feature_11` just to test safe functions w/ target features.
-
-use std::pin::Pin;
 use std::future::Future;
+use std::pin::Pin;
 
 #[target_feature(enable = "sse2")]
-fn target_feature()  -> Pin<Box<dyn Future<Output = ()> + 'static>> { todo!() }
+fn target_feature() -> Pin<Box<dyn Future<Output = ()> + 'static>> {
+    todo!()
+}
 
 fn test(f: impl AsyncFn()) {}
 
diff --git a/tests/ui/async-await/async-closures/fn-exception-target-features.stderr b/tests/ui/async-await/async-closures/fn-exception-target-features.stderr
index 37977b45250..f0846bfdb12 100644
--- a/tests/ui/async-await/async-closures/fn-exception-target-features.stderr
+++ b/tests/ui/async-await/async-closures/fn-exception-target-features.stderr
@@ -1,5 +1,5 @@
 error[E0277]: the trait bound `#[target_features] fn() -> Pin<Box<(dyn Future<Output = ()> + 'static)>> {target_feature}: AsyncFn()` is not satisfied
-  --> $DIR/fn-exception-target-features.rs:16:10
+  --> $DIR/fn-exception-target-features.rs:15:10
    |
 LL |     test(target_feature);
    |     ---- ^^^^^^^^^^^^^^ unsatisfied trait bound
@@ -8,7 +8,7 @@ LL |     test(target_feature);
    |
    = help: the trait `AsyncFn()` is not implemented for fn item `#[target_features] fn() -> Pin<Box<(dyn Future<Output = ()> + 'static)>> {target_feature}`
 note: required by a bound in `test`
-  --> $DIR/fn-exception-target-features.rs:13:17
+  --> $DIR/fn-exception-target-features.rs:12:17
    |
 LL | fn test(f: impl AsyncFn()) {}
    |                 ^^^^^^^^^ required by this bound in `test`