2019-02-03 04:59:37 -06:00
|
|
|
error[E0391]: cycle detected when processing `cycle1::{{opaque}}#0`
|
2018-12-25 09:56:47 -06:00
|
|
|
--> $DIR/auto-trait-leak.rs:14:16
|
2018-07-11 09:01:48 -05:00
|
|
|
|
|
|
|
|
LL | fn cycle1() -> impl Clone {
|
|
|
|
| ^^^^^^^^^^
|
|
|
|
|
|
|
|
|
note: ...which requires processing `cycle1`...
|
2018-12-25 09:56:47 -06:00
|
|
|
--> $DIR/auto-trait-leak.rs:14:1
|
2018-01-15 16:26:36 -06:00
|
|
|
|
|
2018-05-22 07:31:56 -05:00
|
|
|
LL | fn cycle1() -> impl Clone {
|
|
|
|
| ^^^^^^^^^^^^^^^^^^^^^^^^^
|
2018-11-25 15:05:06 -06:00
|
|
|
= note: ...which requires evaluating trait selection obligation `impl std::clone::Clone: std::marker::Send`...
|
2019-02-03 04:59:37 -06:00
|
|
|
note: ...which requires processing `cycle2::{{opaque}}#0`...
|
2018-12-25 09:56:47 -06:00
|
|
|
--> $DIR/auto-trait-leak.rs:23:16
|
2017-11-26 14:32:30 -06:00
|
|
|
|
|
2018-05-22 07:31:56 -05:00
|
|
|
LL | fn cycle2() -> impl Clone {
|
|
|
|
| ^^^^^^^^^^
|
|
|
|
note: ...which requires processing `cycle2`...
|
2018-12-25 09:56:47 -06:00
|
|
|
--> $DIR/auto-trait-leak.rs:23:1
|
2018-01-15 16:26:36 -06:00
|
|
|
|
|
2018-05-22 07:31:56 -05:00
|
|
|
LL | fn cycle2() -> impl Clone {
|
|
|
|
| ^^^^^^^^^^^^^^^^^^^^^^^^^
|
2018-11-25 15:05:06 -06:00
|
|
|
= note: ...which requires evaluating trait selection obligation `impl std::clone::Clone: std::marker::Send`...
|
2019-02-03 04:59:37 -06:00
|
|
|
= note: ...which again requires processing `cycle1::{{opaque}}#0`, completing the cycle
|
2019-01-01 12:08:25 -06:00
|
|
|
note: cycle used when checking item types in top-level module
|
|
|
|
--> $DIR/auto-trait-leak.rs:3:1
|
|
|
|
|
|
|
|
|
LL | / use std::cell::Cell;
|
|
|
|
LL | | use std::rc::Rc;
|
|
|
|
LL | |
|
|
|
|
LL | | fn send<T: Send>(_: T) {}
|
|
|
|
... |
|
|
|
|
LL | | Rc::new(String::from("foo"))
|
|
|
|
LL | | }
|
|
|
|
| |_^
|
2018-07-11 09:01:48 -05:00
|
|
|
|
2019-02-03 04:59:37 -06:00
|
|
|
error[E0391]: cycle detected when processing `cycle1::{{opaque}}#0`
|
2018-12-25 09:56:47 -06:00
|
|
|
--> $DIR/auto-trait-leak.rs:14:16
|
2017-11-26 14:32:30 -06:00
|
|
|
|
|
2018-02-22 18:42:32 -06:00
|
|
|
LL | fn cycle1() -> impl Clone {
|
2018-05-22 07:31:56 -05:00
|
|
|
| ^^^^^^^^^^
|
2018-07-11 09:01:48 -05:00
|
|
|
|
|
|
|
|
note: ...which requires processing `cycle1`...
|
2018-12-25 09:56:47 -06:00
|
|
|
--> $DIR/auto-trait-leak.rs:14:1
|
2018-07-11 09:01:48 -05:00
|
|
|
|
|
|
|
|
LL | fn cycle1() -> impl Clone {
|
|
|
|
| ^^^^^^^^^^^^^^^^^^^^^^^^^
|
2018-11-25 15:05:06 -06:00
|
|
|
= note: ...which requires evaluating trait selection obligation `impl std::clone::Clone: std::marker::Send`...
|
2019-02-03 04:59:37 -06:00
|
|
|
note: ...which requires processing `cycle2::{{opaque}}#0`...
|
2018-12-25 09:56:47 -06:00
|
|
|
--> $DIR/auto-trait-leak.rs:23:16
|
2018-07-11 09:01:48 -05:00
|
|
|
|
|
|
|
|
LL | fn cycle2() -> impl Clone {
|
|
|
|
| ^^^^^^^^^^
|
|
|
|
note: ...which requires processing `cycle2`...
|
2018-12-25 09:56:47 -06:00
|
|
|
--> $DIR/auto-trait-leak.rs:23:1
|
2018-07-11 09:01:48 -05:00
|
|
|
|
|
|
|
|
LL | fn cycle2() -> impl Clone {
|
|
|
|
| ^^^^^^^^^^^^^^^^^^^^^^^^^
|
2019-02-03 04:59:37 -06:00
|
|
|
= note: ...which again requires processing `cycle1::{{opaque}}#0`, completing the cycle
|
2019-01-01 12:08:25 -06:00
|
|
|
note: cycle used when checking item types in top-level module
|
|
|
|
--> $DIR/auto-trait-leak.rs:3:1
|
|
|
|
|
|
|
|
|
LL | / use std::cell::Cell;
|
|
|
|
LL | | use std::rc::Rc;
|
|
|
|
LL | |
|
|
|
|
LL | | fn send<T: Send>(_: T) {}
|
|
|
|
... |
|
|
|
|
LL | | Rc::new(String::from("foo"))
|
|
|
|
LL | | }
|
|
|
|
| |_^
|
2018-07-11 09:01:48 -05:00
|
|
|
|
|
|
|
error[E0277]: `std::rc::Rc<std::string::String>` cannot be sent between threads safely
|
2018-12-25 09:56:47 -06:00
|
|
|
--> $DIR/auto-trait-leak.rs:17:5
|
2018-07-11 09:01:48 -05:00
|
|
|
|
|
|
|
|
LL | send(cycle2().clone());
|
|
|
|
| ^^^^ `std::rc::Rc<std::string::String>` cannot be sent between threads safely
|
|
|
|
|
|
|
|
|
= help: within `impl std::clone::Clone`, the trait `std::marker::Send` is not implemented for `std::rc::Rc<std::string::String>`
|
|
|
|
= note: required because it appears within the type `impl std::clone::Clone`
|
|
|
|
note: required by `send`
|
2018-12-25 09:56:47 -06:00
|
|
|
--> $DIR/auto-trait-leak.rs:6:1
|
2018-07-11 09:01:48 -05:00
|
|
|
|
|
|
|
|
LL | fn send<T: Send>(_: T) {}
|
|
|
|
| ^^^^^^^^^^^^^^^^^^^^^^
|
2017-11-26 14:32:30 -06:00
|
|
|
|
2018-07-11 09:01:48 -05:00
|
|
|
error: aborting due to 3 previous errors
|
2017-11-26 14:32:30 -06:00
|
|
|
|
2019-04-17 12:26:38 -05:00
|
|
|
Some errors have detailed explanations: E0277, E0391.
|
2018-07-11 09:01:48 -05:00
|
|
|
For more information about an error, try `rustc --explain E0277`.
|