News for hackers. Stuff that matters.
Re:Async Rust Is A Bad Language by Pauan on Friday September 08, 2023 @01:46PM (#37436892)
Rust Futures are essentially green threads, except much lighter-weight, much faster, and implemented in user space instead of being built-in to the language.

Basically Rust Futures is what Go wishes it could have. Rust made the right choice in waiting and spending the time to design async right.

Re:Async Rust Is A Bad Language by vacuity on Friday September 08, 2023 @10:01PM (#37441462)
You're overstating your case. Rust's async tasks (based on stackless coroutines) and Go's goroutines (based on stackful coroutines) have important differences. Rust's design introduces function coloring (tentative solution in progress) but is much more suited for the bare-metal scene that C and C++ are famous for. Go's design has more overhead but, by virtue of not having colored functions, is simpler for programmers to write code for. Most things in computer science/programming involve tradeoffs. Also, Rust's async/await is built-in to the language. It's not a library implementation of stackless coroutines.
Re:Async Rust Is A Bad Language by pkolaczk on Saturday September 09, 2023 @04:46AM (#37443417)
> Go's design has more overhead but, by virtue of not having colored functions, is simpler for programmers to write code for.

Colored functions is a debatable problem at best. I consider it a feature not a bug and it makes reasoning about programs easier at the expense of writing additional async/await keywords which is really a very minor annoyance.

On the other hand Go's need of using channels to do trivial and common tasks like communicating the result of an async task together with the lack of RAII and proper cleanup signaling in channels (you can very easily deadlock if nothing is attached on the other end of the channel), plus no compile time race detection - all that makes writing concurrent code harder.

Re:Async Rust Is A Bad Language by cdelsolar on Saturday September 09, 2023 @10:51PM (#37452455)
ok lol