blob: ffe486d446822afc42ec22d2dc5d94b844ff054f [file] [log] [blame]
error[E0277]: `F` cannot be shared between threads safely
--> $DIR/closure-bounds-subtype.rs:24:5
|
LL | take_const_owned(f); //~ ERROR `F` cannot be shared between threads safely [E0277]
| ^^^^^^^^^^^^^^^^ `F` cannot be shared between threads safely
|
= help: the trait `std::marker::Sync` is not implemented for `F`
= help: consider adding a `where F: std::marker::Sync` bound
note: required by `take_const_owned`
--> $DIR/closure-bounds-subtype.rs:15:1
|
LL | fn take_const_owned<F>(_: F) where F: FnOnce() + Sync + Send {
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
error: aborting due to previous error
For more information about this error, try `rustc --explain E0277`.