diff options
Diffstat (limited to 'src')
| -rw-r--r-- | src/test/ui/async-await/issues/issue-67893.rs | 2 | ||||
| -rw-r--r-- | src/test/ui/async-await/issues/issue-67893.stderr | 15 |
2 files changed, 3 insertions, 14 deletions
diff --git a/src/test/ui/async-await/issues/issue-67893.rs b/src/test/ui/async-await/issues/issue-67893.rs index f34ce8081ca..8b53408d758 100644 --- a/src/test/ui/async-await/issues/issue-67893.rs +++ b/src/test/ui/async-await/issues/issue-67893.rs @@ -7,5 +7,5 @@ fn g(_: impl Send) {} fn main() { g(issue_67893::run()) - //~^ ERROR: `MutexGuard<'_, ()>` cannot be sent between threads safely + //~^ ERROR generator cannot be sent between threads safely } diff --git a/src/test/ui/async-await/issues/issue-67893.stderr b/src/test/ui/async-await/issues/issue-67893.stderr index c4b55e6ec20..7321a38c021 100644 --- a/src/test/ui/async-await/issues/issue-67893.stderr +++ b/src/test/ui/async-await/issues/issue-67893.stderr @@ -1,20 +1,10 @@ -error[E0277]: `MutexGuard<'_, ()>` cannot be sent between threads safely +error: generator cannot be sent between threads safely --> $DIR/issue-67893.rs:9:5 | LL | g(issue_67893::run()) - | ^ `MutexGuard<'_, ()>` cannot be sent between threads safely - | - ::: $DIR/auxiliary/issue_67893.rs:7:20 - | -LL | pub async fn run() { - | - within this `impl Future` + | ^ generator is not `Send` | = help: within `impl Future`, the trait `Send` is not implemented for `MutexGuard<'_, ()>` - = note: required because it appears within the type `for<'r, 's, 't0, 't1, 't2, 't3> {ResumeTy, Arc<Mutex<()>>, &'r Mutex<()>, Result<MutexGuard<'s, ()>, PoisonError<MutexGuard<'t0, ()>>>, &'t1 MutexGuard<'t2, ()>, MutexGuard<'t3, ()>, (), impl Future}` - = note: required because it appears within the type `[static generator@run::{closure#0}]` - = note: required because it appears within the type `from_generator::GenFuture<[static generator@run::{closure#0}]>` - = note: required because it appears within the type `impl Future` - = note: required because it appears within the type `impl Future` note: required by a bound in `g` --> $DIR/issue-67893.rs:6:14 | @@ -23,4 +13,3 @@ LL | fn g(_: impl Send) {} error: aborting due to previous error -For more information about this error, try `rustc --explain E0277`. |
