upvote
Lean is great. But these days with Aristotle you can check memory safety for other languages like C so it's not totally obvious it's worth rewriting everything in Rust.
reply
Right, but Aristotle easily burned my initial $500 free credits doing so. Rust's memory safety is pretty cheap in comparison.
reply
Working on it...
reply
Doesn't Aristole work by compiling to Lean?
reply
I would go with English, generating directly machine code, as dreamed by 4 GL and Japan's fifth generation project.

You can already see this taking of on low code, no code tooling, reinvented as SaaS agentic runtimes.

Or check SIGPLAN papers on machine learning based compilers.

reply
> Or check SIGPLAN papers on machine learning based compilers.

Mind providing some examples? My (admittedly probably dated) understanding of how ML is used in compilers is for picking heuristics/thresholds/other things for which there's no known optimal "right" answer (e.g., pass order, inlining thresholds). Everything else was done in the "traditional" manner, which meant that the machine learning bits were, strictly speaking, completely optional. I haven't heard of compilers where ML techniques are integral to the process to the point where removing any ML bits would result in a nonfunctional compiler.

reply
A recent example,

"Compiler 2.0: Building the Next Generation Compilers with Machine Learning"

https://www.youtube.com/watch?v=FnXEmPwdPDA

reply
Thanks! Looks like some interesting developments indeed, and I will have to update my understanding accordingly.
reply
Rust is a terrible language for many of the tasks people try to shoehorn it into. As processors and memory get faster, garbage collection only becomes more attractive, while the borrow checker remains a PITA that gets in the way of plenty of sensible architectures. In a sane world, Rust will never take over frontend development, for example - it’s a terrible fit.

(I qualify with “in a sane world” because obviously it could happen. In a truly sane world, JavaScript would never have happened, either!)

reply
> As processors and memory get faster, garbage collection only becomes more attractive, while the borrow checker remains a PITA that gets in the way of plenty of sensible architectures.

I’d counter with: as LLM driven coding becomes more and more common the PITA borrow checker is something individual developers interact with less than less. Garbage collection looks more and more like a waste when an LLM can examine memory allocations before the app is even built.

reply
Maybe, but whatever workarounds or compromises the LLM has to settle on to satisfy the borrow checker will live in the code forever, while garbage collection can continue to get faster in the same executable.
reply
Rust code tend to be "better" because those concerns forces the architecture upfront and guaranteed that nothing breaks later on.
reply
Eh. In my experience any long-running Rust project will go through a lot of refactors, often driven by borrow checker issues. The only bright spot is that the compiler makes them relatively easy and safe. But it would be better not to have to do them in the first place if your architecture is already solid, just not in a way that the borrow checker understands.
reply
The same arguments could often apply to Zig with 100% up-front static allocation (like TigerBeetle uses).
reply
> As processors and memory get faster, garbage collection only becomes more attractive

Just because they did in the past doesn't mean they will continue to do so in the future. If we are honest then Moore's Law ended a decade ago (the latest) and we've been picking the low hanging fruit we left alone during Moore's era since. This too will come to an end for sure, just not a pretty and well defined one.

So, my conclusion is the opposite. Garbage collected and DX optimized languages made sense while processors and memory got faster, the future will be elsewhere.

reply
Did Moore’s Law really end? My ARM Mac from five years ago is a literal order of magnitude faster than a gigantic, beefy desktop tower from five years before that, and my newest ARM Mac from this year is another 5x or so faster than my first. Computers continue to get much, much faster, at least in terms of time to completion of normal workloads.
reply
As processors and memory get faster, people will expect more from them. And the fact that languages like Rust give you fine-grained control over memory allocation is part of what allows it to be so performant on modern hardware where memory latency is still relatively high and bandwidth still relatively low. My intuition is that any data-intensive operation (such as blurring an image) will almost always be far faster in rust than javascript.
reply
deleted
reply
I think most of those tradeoffs flip as more of the engineering is done by AI systems. I think that's true on its own, but it's especially true if those systems are increasingly capable of autonomously verifying their own correctness.
reply
I'm not advocating for Rust (or against it), I'm just stating that currently it's hard to open the news without seeing Rust expanding somewhere, and it feels like "taking over the world". Whether that is bad or good is another question.

And yeah, it feels a bit like JavaScript a while ago, that's a good comparison.

reply
That's true and there are some truly high throughput systems that absolutely benefit from garbage collection (I've written one of them, and can't sing enough praises of not one but several java garbage collection types), but there are two problems here:

1) most garbage collectors are pretty lame and can't even come close to the throughput/efficiency of manually managed memory, and

2) the vast majority of software does not even come close to the frontier of what is possible with software, and therefore the thing that matters most is correctness.

Rust does a better job at correctness than most languages because the type system is so robust, and it does a better job at memory management than most languages because most languages do garbage collection so poorly.

reply
I wonder if Rust is really bad for UI or UI code is just a mess of terrible practices like having event listeners for everything.
reply
I don’t think you can do a “you’re holding it wrong” with UI code when it seems like every UI framework eventually evolves to let people hold it that way. People find it difficult to build fully-featured UI frameworks in Rust, and people writing UIs don’t tend to pick Rust frameworks. They aren’t wrong for that!
reply
> In a truly sane world, JavaScript would never have happened, either!

Out of curiosity, what do you envision would have taken its place in frontend, in that sane world? (Honest question, no bad faith agenda.)

reply
No language that perfectly fills that niche exists, because none was ever needed. JavaScript eventually became Good Enough. Python is OK, but it’s an old language at this point and it suffers a lot of technical debt.

JavaScript’s biggest weakness IMO is its absolutely abysmal standard library, particularly in terms of data structures. (At least we have Map and Set now, but still no way to define a hash/equality function for a type…) The situation is so bad that essentially any other modern programming language would be an improvement.

reply
I for one wish python had taken the spot JavaScript holds.
reply
This all says more about you and your experience than about rust
reply
How so?
reply