Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

std::rc::Weak<ContextImpl>` cannot be sent between threads safely #175

Open
zhukui opened this issue Aug 2, 2022 · 0 comments
Open

std::rc::Weak<ContextImpl>` cannot be sent between threads safely #175

zhukui opened this issue Aug 2, 2022 · 0 comments

Comments

@zhukui
Copy link

zhukui commented Aug 2, 2022

How to solve this question ? I want to use context in 'thread::spawn' block ! The error message is blow :

error[E0277]: std::rc::Weak<ContextImpl> cannot be sent between threads safely
--> src/event_channels.rs:154:32
|
154 | sender.send(move || {
| ^^^^ std::rc::Weak<ContextImpl> cannot be sent between threads safely
|
= help: within event_channels::EventChannels, the trait std::marker::Send is not implemented for std::rc::Weak<ContextImpl>
= note: required because it appears within the type nativeshell::Context

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant