Hacker News new | ask | show | jobs
by ori_b 973 days ago
Futures are nicely equivalent to one shot channels with threads.
2 comments

Not quite: Rust futures also have immediate cancellation and easy timeouts that can be imposed externally on any future.

In threads that perform blocking I/O you don't get that, and need to support timeouts and cancellation explicitly in every blocking call.

With a nice syntax sugar on top, but yeah pretty much.