1 error: future cannot be sent between threads safely
2 --> $DIR/issue-71137.rs:20:3
4 LL | fn fake_spawn<F: Future + Send + 'static>(f: F) { }
5 | ---- required by this bound in `fake_spawn`
7 LL | fake_spawn(wrong_mutex());
8 | ^^^^^^^^^^ future returned by `wrong_mutex` is not `Send`
10 = help: within `impl Future`, the trait `Send` is not implemented for `MutexGuard<'_, i32>`
11 note: future is not `Send` as this value is used across an await
12 --> $DIR/issue-71137.rs:12:5
14 LL | let mut guard = m.lock().unwrap();
15 | --------- has type `MutexGuard<'_, i32>` which is not `Send`
16 LL | (async { "right"; }).await;
17 | ^^^^^^^^^^^^^^^^^^^^^^^^^^ await occurs here, with `mut guard` maybe used later
20 | - `mut guard` is later dropped here
22 error: aborting due to previous error