]> git.lizzy.rs Git - rust.git/blob - src/test/ui/issue-40827.stderr
Auto merge of #54624 - arielb1:evaluate-outlives, r=nikomatsakis
[rust.git] / src / test / ui / issue-40827.stderr
1 error[E0277]: `std::rc::Rc<Foo>` cannot be sent between threads safely
2   --> $DIR/issue-40827.rs:24:5
3    |
4 LL |     f(Foo(Arc::new(Bar::B(None))));
5    |     ^ `std::rc::Rc<Foo>` cannot be sent between threads safely
6    |
7    = help: within `Bar`, the trait `std::marker::Send` is not implemented for `std::rc::Rc<Foo>`
8    = note: required because it appears within the type `Bar`
9    = note: required because of the requirements on the impl of `std::marker::Send` for `std::sync::Arc<Bar>`
10    = note: required because it appears within the type `Foo`
11 note: required by `f`
12   --> $DIR/issue-40827.rs:21:1
13    |
14 LL | fn f<T: Send>(_: T) {}
15    | ^^^^^^^^^^^^^^^^^^^
16
17 error[E0277]: `std::rc::Rc<Foo>` cannot be shared between threads safely
18   --> $DIR/issue-40827.rs:24:5
19    |
20 LL |     f(Foo(Arc::new(Bar::B(None))));
21    |     ^ `std::rc::Rc<Foo>` cannot be shared between threads safely
22    |
23    = help: within `Bar`, the trait `std::marker::Sync` is not implemented for `std::rc::Rc<Foo>`
24    = note: required because it appears within the type `Bar`
25    = note: required because of the requirements on the impl of `std::marker::Send` for `std::sync::Arc<Bar>`
26    = note: required because it appears within the type `Foo`
27 note: required by `f`
28   --> $DIR/issue-40827.rs:21:1
29    |
30 LL | fn f<T: Send>(_: T) {}
31    | ^^^^^^^^^^^^^^^^^^^
32
33 error: aborting due to 2 previous errors
34
35 For more information about this error, try `rustc --explain E0277`.