1 error: future cannot be sent between threads safely
2 --> $DIR/issue-68112.rs:34:5
4 LL | require_send(send_fut);
5 | ^^^^^^^^^^^^ future created by async block is not `Send`
7 = help: the trait `Sync` is not implemented for `RefCell<i32>`
8 note: future is not `Send` as it awaits another future which is not `Send`
9 --> $DIR/issue-68112.rs:31:17
11 LL | let _ = non_send_fut.await;
12 | ^^^^^^^^^^^^ await occurs here on type `impl Future<Output = Arc<RefCell<i32>>>`, which is not `Send`
13 note: required by a bound in `require_send`
14 --> $DIR/issue-68112.rs:11:25
16 LL | fn require_send(_: impl Send) {}
17 | ^^^^ required by this bound in `require_send`
19 error: future cannot be sent between threads safely
20 --> $DIR/issue-68112.rs:43:5
22 LL | require_send(send_fut);
23 | ^^^^^^^^^^^^ future created by async block is not `Send`
25 = help: the trait `Sync` is not implemented for `RefCell<i32>`
26 note: future is not `Send` as it awaits another future which is not `Send`
27 --> $DIR/issue-68112.rs:40:17
29 LL | let _ = make_non_send_future1().await;
30 | ^^^^^^^^^^^^^^^^^^^^^^^ await occurs here on type `impl Future<Output = Arc<RefCell<i32>>>`, which is not `Send`
31 note: required by a bound in `require_send`
32 --> $DIR/issue-68112.rs:11:25
34 LL | fn require_send(_: impl Send) {}
35 | ^^^^ required by this bound in `require_send`
37 error[E0277]: `RefCell<i32>` cannot be shared between threads safely
38 --> $DIR/issue-68112.rs:60:5
40 LL | require_send(send_fut);
41 | ^^^^^^^^^^^^ `RefCell<i32>` cannot be shared between threads safely
43 = help: the trait `Sync` is not implemented for `RefCell<i32>`
44 = note: required because of the requirements on the impl of `Send` for `Arc<RefCell<i32>>`
45 = note: required because it appears within the type `[static generator@$DIR/issue-68112.rs:47:31: 47:36]`
46 = note: required because it appears within the type `from_generator::GenFuture<[static generator@$DIR/issue-68112.rs:47:31: 47:36]>`
47 = note: required because it appears within the type `impl Future<Output = [async output]>`
48 = note: required because it appears within the type `impl Future<Output = Arc<RefCell<i32>>>`
49 = note: required because it appears within the type `impl Future<Output = Arc<RefCell<i32>>>`
50 = note: required because it appears within the type `{ResumeTy, impl Future<Output = Arc<RefCell<i32>>>, (), i32, Ready<i32>}`
51 = note: required because it appears within the type `[static generator@$DIR/issue-68112.rs:55:26: 59:6]`
52 = note: required because it appears within the type `from_generator::GenFuture<[static generator@$DIR/issue-68112.rs:55:26: 59:6]>`
53 = note: required because it appears within the type `impl Future<Output = [async output]>`
54 note: required by a bound in `require_send`
55 --> $DIR/issue-68112.rs:11:25
57 LL | fn require_send(_: impl Send) {}
58 | ^^^^ required by this bound in `require_send`
60 error: aborting due to 3 previous errors
62 For more information about this error, try `rustc --explain E0277`.