2 ms·
> At this point wouldn't it be better to just use a regular GC language? No, because you wouldn't slap `Arc` on every single variable. The example from the blo
by drogus 4y ago
> At this point wouldn't it be better to just use a regular GC language?
No, because you wouldn't slap `Arc` on every single variable. The example from the blog post is a dispatcher and `Arc` is then needed for dispatched functions. The same might be true for queues and other stuff where you need to move stuff between threads, but other than that it would be mostly `Arc` free.
As an example: when you write a web service in one of the frameworks like Actix, you typically use `Arc` for stuff that you need to share between all of the handlers like DB connections, queues, counters etc. All of the other stuff would be relatively straightforward Rust without much consideration for lifetimes.