3 ms·
Exactly. Here's my experience using LLMs to produce code: - Rust: nearly universally compiles and runs without fault. - Python,JS: very often will run for som
by sockaddr 7mo ago
Exactly. Here's my experience using LLMs to produce code:
- Rust: nearly universally compiles and runs without fault.
- Python,JS: very often will run for some time and then crash
The reason I think is type safety and the richness of the compiler errors and warnings. Rust is absolutely king here.
- 9rx 7mo ago[flagged]
- satvikpendem 7mo agoWhat will you use for dependent types, Idris 2? Lean? None are as popular as Rust especially counting the number of production level packages available.
- valenterry 7mo agoScala has dependant types (though inferior than Idris ones) and has the whole jvm ecosystem.
- sockaddr 7mo agoThis is quite sad to see someone react to a comment they disagree with by assuming that different opinion is paid for. I'd love it if you dug into my comment history and found even a shred of evidence that I'm being paid to talk positively about my programming language of choice. I hope there aren't many of your type on here.
- 9rx 7mo agoAll comments are paid for in some way, even if only in "warm fuzzies". If that is sad, why are you choosing to be sad? But outlandish comments usually require greater payment to justify someone putting in the effort. If you're not being paid well, what's the motivation to post things you know don't make any sense to try and sell a brand?
- sockaddr 7mo ago> If you're not being paid well, what's the motivation to post things you know don't make any sense to try and sell a brand? Because it works. Because it does in fact make sense despite your frustration with the concept.
- 9rx 7mo agoRight. So why did you deny it earlier?
- sockaddr 7mo agoI'm answering the part of your question about why I post about something that I find works. Are you this dense in real life or is this an act?
- 9rx 7mo agoIs a computer dense in real life? Does that not go without saying? Are you under the impression that HN is some kind of intelligent animal?
- chillfox 7mo agoIsn’t dependent types replicating the object oriented inheritance problem in the type system?
- 9rx 7mo agoNo, unless you mean the problem of over-engineering? In which case, yes, that is a realistic concern. In the real world, tests are quite often more than good enough. And since they are good enough they end up covering all the same cases a half-assed type system is able to assert anyway by virtue of the remaining logic needing to be tested, so the type system doesn't become all that important in the first place. A half-assed type system is helpful for people writing code by hand. Then you get things like the squiggly lines in your editor and automated refactoring tools, which are quite beneficial for productivity. However, when an LLM is writing code none of that matters. It doesn't care one bit if the failure reports comes from the compiler or the test suite. It is all the same to it.
- ses1984 7mo agoI’m not sure they’re saying rust is king of types, they’re saying it’s king of llm targets.
- hu3 7mo agoWhich it obviously can't be because it has an anemic standard library and depends on creates for basic things like error handling and async. Not to mention it's one of the slowest compilation of recent languages if not the slowest (maybe Kotlin).
- ses1984 7mo agoBut there is no language that is best in all of these dimensions (including ones described above). Everything is a trade-off.
- lmf4lol 7mo agoI ve just vibed for 2 weeks a pretty complex Python+Next.js app. I've forced Codex into TDD, so everything(!) has to be tested. So far, it is really really stable and type errors haven't been a thing yet. Not wanting to disagree, I am sure with Rust, it would be even more stable.