logoalt Hacker News

Aurornisyesterday at 10:49 PM1 replyview on HN

Rust's compile-time checks are actually a nice set of guardrails for LLMs.

Nobody who works with LLM generated code believes that LLMs produce fault-free code.


Replies

jesseschalkentoday at 6:20 AM

Yes, languages with very strong type systems like Rust are incredible when paired with an LLM. Just like chat bots have a calculator as a "tool" because they are not the best at calculation themselves, they need a type system to deterministically validate the safety and cohesion of the code they generate.

Its languages like C that you have to watch out for, because the LLM will gladly say "this is safe!" when its not.