Future trait - Waking the waker without using a thread

⚓ Rust    📅 2025-10-18    👤 surdeus    👁️ 9      

surdeus

Warning

This post was published 62 days ago. The information described in this article may have changed.

Hello,

I am trying to implement the Future trait.

Unfortunately where I am having difficulties is with the waking part of the Waker from the Context.

As of now the best way I see to be sure to know when to wake the waker is to have another thread watching when to wake the waker. But I feel that by doing that the async part is just "lost".

What are the best practices ?

Thank you very much in advance for any help.

Hoping I was clear enough

9 posts - 5 participants

Read full topic

🏷️ Rust_feed