]> git.lizzy.rs Git - rust.git/blob - src/test/ui/recursion/recursive-requirements.stderr
Auto merge of #86155 - alexcrichton:abort-on-unwind, r=nikomatsakis
[rust.git] / src / test / ui / recursion / recursive-requirements.stderr
1 error[E0277]: `*const Bar` cannot be shared between threads safely
2   --> $DIR/recursive-requirements.rs:16:12
3    |
4 LL | struct AssertSync<T: Sync>(PhantomData<T>);
5    |                      ---- required by this bound in `AssertSync`
6 ...
7 LL |     let _: AssertSync<Foo> = unimplemented!();
8    |            ^^^^^^^^^^^^^^^ `*const Bar` cannot be shared between threads safely
9    |
10    = help: within `Foo`, the trait `Sync` is not implemented for `*const Bar`
11 note: required because it appears within the type `Foo`
12   --> $DIR/recursive-requirements.rs:5:12
13    |
14 LL | pub struct Foo {
15    |            ^^^
16
17 error[E0277]: `*const Foo` cannot be shared between threads safely
18   --> $DIR/recursive-requirements.rs:16:12
19    |
20 LL | struct AssertSync<T: Sync>(PhantomData<T>);
21    |                      ---- required by this bound in `AssertSync`
22 ...
23 LL |     let _: AssertSync<Foo> = unimplemented!();
24    |            ^^^^^^^^^^^^^^^ `*const Foo` cannot be shared between threads safely
25    |
26    = help: within `Foo`, the trait `Sync` is not implemented for `*const Foo`
27 note: required because it appears within the type `Bar`
28   --> $DIR/recursive-requirements.rs:10:12
29    |
30 LL | pub struct Bar {
31    |            ^^^
32    = note: required because it appears within the type `PhantomData<Bar>`
33 note: required because it appears within the type `Foo`
34   --> $DIR/recursive-requirements.rs:5:12
35    |
36 LL | pub struct Foo {
37    |            ^^^
38
39 error: aborting due to 2 previous errors
40
41 For more information about this error, try `rustc --explain E0277`.