fork/rust

git clone https://git.julia.blue/fork/rust

borsAuto merge of #71365 - Mark-Simulacrum:stable-next, r=Mark-Simulacrum4fb7144ed15

1.43.0
1.3 KiB29 linesraw
1error[E0277]: `*const Bar` cannot be shared between threads safely
2  --> $DIR/recursive-requirements.rs:16:12
3   |
4LL | struct AssertSync<T: Sync>(PhantomData<T>);
5   | ------------------------------------------- required by `AssertSync`
6...
7LL |     let _: AssertSync<Foo> = unimplemented!();
8   |            ^^^^^^^^^^^^^^^ `*const Bar` cannot be shared between threads safely
9   |
10   = help: within `Foo`, the trait `std::marker::Sync` is not implemented for `*const Bar`
11   = note: required because it appears within the type `Foo`
12
13error[E0277]: `*const Foo` cannot be shared between threads safely
14  --> $DIR/recursive-requirements.rs:16:12
15   |
16LL | struct AssertSync<T: Sync>(PhantomData<T>);
17   | ------------------------------------------- required by `AssertSync`
18...
19LL |     let _: AssertSync<Foo> = unimplemented!();
20   |            ^^^^^^^^^^^^^^^ `*const Foo` cannot be shared between threads safely
21   |
22   = help: within `Foo`, the trait `std::marker::Sync` is not implemented for `*const Foo`
23   = note: required because it appears within the type `Bar`
24   = note: required because it appears within the type `std::marker::PhantomData<Bar>`
25   = note: required because it appears within the type `Foo`
26
27error: aborting due to 2 previous errors
28
29For more information about this error, try `rustc --explain E0277`.