That’s why it’s amazing, type safe efficient multi-threading without dynamic memory allocation with a nice syntax...it’s the holy grail of server programming.
Yeah, the good thing is that the devs are always happy to take feedback on improving the error messages (like explaining differences between Fn/FnMut/fn here)
Why would I want to write a server in a language that requires such awkward approaches to basics like coroutines and dynamic dispatch when I could use kotlin on the JVM and get pauseless GC, ultra fast edit/compile/run cycles, efficient and powerful coroutines, and eventually Loom which will eliminate the whole problem of coloured functions completely and let me just forget about coroutines? Multi threading bugs are not so common in real Java/Kotlin programs to justify this epic set of costs, in my view.
Have you ever tried writing the same application on both a JVM language and in Rust, and then measuring the latency & throughput differentials? Blew my mind the first time.
Of course, if speed isn’t a concern for you, then please carry on.
Modern JVM GCs have pause times below 1msec. That's a new capability though so most people aren't yet aware of it.
And Google's ads backend are hardly the definition of server. Their ads front-end for example always used to be in Java. Not sure what it is these days
Everything is "mismatched types" in Rust, literally it doesn't do any automatic type conversion (casting), so it's not the right language for most people.
I did read the article; it's overly focused on async (especially the headline). The body quite correctly analyses the problem with functions, but misses that this is much more general than async; just adopting a different async model isn't a solution.
Well, the article’s focus is on asynchrony. Naturally then, it talks about closures within the context of asynchrony and to the extent that it is relevant.
The author could have made the topic about closures, but that’s not what they wanted to talk about.
The author's focus on async leads them to the wrong conclusion. Not adopting async would not have solved the fundamental underlying problem; the perennial issues with error handling in Rust are another manifestation of the same problem, and as soon as people start trying to do things like database transaction management they'll hit the same problem again. Ripping async out of Rust isn't a solution; this problem will come up again and again unless and until Rust implements proper first-class functions.
I know what you’re saying, but at some point you could argue we “ARE eating the wrong thing”, considering our population size.
Said differently, I hypothesize that it would be more practicable to create policies that influence what we eat and how that food is produced, compared to creating policies that try to reduce population size. If anything, it appears that more advanced countries are competing to gain population so that the machinery of their societies can keep chugging along in the name of growth.
EDIT: elsewhere in the thread I see people comment on multi-use of animals vs plants, and the consequent implication of increased use of undesirable synthetics/plastics if we raise fewer animals. Systems get complex, and their behavior can change drastically in surprising ways if you start fiddling. But fiddling we must.
I’ve got a good set of speakers, and coupled with Tidal’s Master[1] quality recordings, there’s just no way I can go back to something of lower sound fidelity.
Because what people fail to understand is that from source -> listener there are multiple points at which information is lost. People obsess over the file format but not over which DAC they use or whether Apple, Spotify, Tidal has better encoding capabilities.
> You can go also go full Rosetta: create an alias to your terminal, right-click enable "Run in Rosetta", open it, then everything you run from this terminal will also be Rosetta (amd64), and you run Rosetta homebrew, node, etc. You can confirm what is running under Rosetta in Activity Monitor.
The compiler complained: “error[E0308]: mismatched types”