Before everyone downvote me Edit: i meant to say is, understanding threads and passing data between them is quite hard for new comer. There is also macros, which i would gladly stay away.
(I might be dumb that’s why i found it hard to graps)
Multithreading? Rust has great support for multithreading, and will even help you avoid data races.
Do you mean asynchronous code? (A.k.a. async-await?) That's definitely newer and a bit trickier—it's also an area of focus for the Rust developers and improving. But yeah, some sharp edges there.
The advice I've seen is to stick with synchronous (single thread or threaded) Rust while you're learning, until you need a level of concurrency that OS threads can't support. (Or need to target an embedded system without OS threads.) I think I agree with that, and you can do a lot with good ol' threads. Most people aren't writing the next high-performance HTTP server.
Quite the opposite! I did a full duplex websocket based program, that's a multithreaded nightmare! The compiler/general language design stopped me from foot gunning myself more times than I can count, I learn to appreciate it a lot more after that.
View all comments
Show parent comment
-10
u/parthvsquare Sep 13 '23 edited Sep 13 '23
Multi threading in rust is a nightmare
Before everyone downvote me Edit: i meant to say is, understanding threads and passing data between them is quite hard for new comer. There is also macros, which i would gladly stay away.
(I might be dumb that’s why i found it hard to graps)