1 error[E0277]: `UnsafeCell<MySync<{integer}>>` cannot be shared between threads safely
2 --> $DIR/typeck-unsafe-always-share.rs:19:10
5 | ---- ^^ `UnsafeCell<MySync<{integer}>>` cannot be shared between threads safely
7 | required by a bound introduced by this call
9 = help: the trait `Sync` is not implemented for `UnsafeCell<MySync<{integer}>>`
10 note: required by a bound in `test`
11 --> $DIR/typeck-unsafe-always-share.rs:15:12
13 LL | fn test<T: Sync>(s: T) {}
14 | ^^^^ required by this bound in `test`
16 error[E0277]: `UnsafeCell<NoSync>` cannot be shared between threads safely
17 --> $DIR/typeck-unsafe-always-share.rs:23:10
20 | ---- ^^^ `UnsafeCell<NoSync>` cannot be shared between threads safely
22 | required by a bound introduced by this call
24 = help: the trait `Sync` is not implemented for `UnsafeCell<NoSync>`
25 note: required by a bound in `test`
26 --> $DIR/typeck-unsafe-always-share.rs:15:12
28 LL | fn test<T: Sync>(s: T) {}
29 | ^^^^ required by this bound in `test`
31 error[E0277]: `UnsafeCell<NoSync>` cannot be shared between threads safely
32 --> $DIR/typeck-unsafe-always-share.rs:27:10
35 | ---- ^^ `UnsafeCell<NoSync>` cannot be shared between threads safely
37 | required by a bound introduced by this call
39 = help: within `MySync<NoSync>`, the trait `Sync` is not implemented for `UnsafeCell<NoSync>`
40 note: required because it appears within the type `MySync<NoSync>`
41 --> $DIR/typeck-unsafe-always-share.rs:8:8
43 LL | struct MySync<T> {
45 note: required by a bound in `test`
46 --> $DIR/typeck-unsafe-always-share.rs:15:12
48 LL | fn test<T: Sync>(s: T) {}
49 | ^^^^ required by this bound in `test`
51 error[E0277]: `NoSync` cannot be shared between threads safely
52 --> $DIR/typeck-unsafe-always-share.rs:30:10
55 | ---- ^^^^^^ `NoSync` cannot be shared between threads safely
57 | required by a bound introduced by this call
59 = help: the trait `Sync` is not implemented for `NoSync`
60 note: required by a bound in `test`
61 --> $DIR/typeck-unsafe-always-share.rs:15:12
63 LL | fn test<T: Sync>(s: T) {}
64 | ^^^^ required by this bound in `test`
66 error: aborting due to 4 previous errors
68 For more information about this error, try `rustc --explain E0277`.