Hacker News new | ask | show | jobs
by viraptor 21 days ago
> You don’t even understand my point.

What if you didn't understand the comment?

Full validation of spec to implementation is still close to impossible and nothing that exists today will get us there outside of extremely limited scope. But some language features make the gap just a bit smaller. The less you have to look at details and more at the actual structure, the more you can be sure the implementation matches what you want.

Extreme, unrealistic case: you want to add something to a list of samples - one implementation does list.add(sample), the other inlines all the reference counting, object cloning, memory allocation and possible extension of list over 100 lines. How sure are you that either one of those implements what you want? Now reduce that to more realistic scenarios where C still forces you to either be more verbose or less explicit, while Rust (or any other more expressive language) lets you show exactly what's needed via better features or via types.

> Does it know anything about quantiles or student t distributions and will warn the agent if it implements them wrong?

No, we're not even close to that. But it lets you use stylo and implement `student(PositiveInteger v)`, which you can't achieve in C. So again - nothing can eliminate that gap today, but language features can definitely make it smaller.

1 comments

Does that actually exist or is it wishful thinking? People keep telling me this but whenever I look at vibecoded Rust projects it’s the worst kind of abstraction mess I have ever seen. This project here isn’t any different and the author is obviously just throwing stuff against the wall to see if anything sticks. What closes the gap is conventions and abstractions the AI can rely on which is why most AI Rust code looks like crap as there’s just too many ways to do things, AI written Python or even JS code is much simpler in comparison. Never seen a good vibe coded Rust code base if you know anything let me know.
It exists minimally in every place that uses Option/Result instead of a value that can be misinterpreted or accidentally ignored. How far further things go depends on the author. Even without asking for much in cases like this https://github.com/storytold/filmcraft/blob/a65d1e97e85aeaec... I can imagine C code having so many issues... (Nonexclusive matching, tagging mistakes, accessible uninitialised memory, etc.)