1 error[E0277]: `Sender<i32>` cannot be shared between threads safely
2 --> $DIR/issue-70935-complex-spans.rs:13:45
4 LL | fn foo(tx: std::sync::mpsc::Sender<i32>) -> impl Future + Send {
5 | ^^^^^^^^^^^^^^^^^^ `Sender<i32>` cannot be shared between threads safely
7 = help: the trait `Sync` is not implemented for `Sender<i32>`
8 = note: required for `&Sender<i32>` to implement `Send`
9 note: required because it's used within this closure
10 --> $DIR/issue-70935-complex-spans.rs:17:13
14 note: required because it's used within this `async fn` body
15 --> $DIR/issue-70935-complex-spans.rs:10:67
17 LL | async fn baz<T>(_c: impl FnMut() -> T) where T: Future<Output=()> {
18 | ___________________________________________________________________^
21 = note: required because it captures the following types: `ResumeTy`, `impl Future<Output = ()>`, `()`
22 note: required because it's used within this `async` block
23 --> $DIR/issue-70935-complex-spans.rs:16:16
28 LL | | foo(tx.clone());
33 error: aborting due to previous error
35 For more information about this error, try `rustc --explain E0277`.