]>
git.proxmox.com Git - rustc.git/blob - tests/ui/kindck/kindck-send-object2.rs
1 // Continue kindck-send-object1.rs.
3 fn assert_send
<T
:Send
>() { }
7 assert_send
::<&'
static dyn Dummy
>();
8 //~^ ERROR `(dyn Dummy + 'static)` cannot be shared between threads safely [E0277]
12 assert_send
::<Box
<dyn Dummy
>>();
13 //~^ ERROR `dyn Dummy` cannot be sent between threads safely
16 // ...unless they are properly bounded
18 assert_send
::<&'
static (dyn Dummy
+ Sync
)>();
21 assert_send
::<Box
<dyn Dummy
+ Send
>>();