Rust in the 6.2 kernel
Rust in the 6.2 kernel
Posted Nov 19, 2022 22:45 UTC (Sat) by khim (subscriber, #9252)In reply to: Rust in the 6.2 kernel by gasche
Parent article: Rust in the 6.2 kernel
I think you are talking past each other.
> Even if the Rust system *could* in theory express logical proofs (Coq or Agda can, for example), it would be entirely possible to write code that contains bugs in the language (at less precise types).Rust type system can express logical proofs and it's not possible to circumvent it (except for bugs in the compiler, of course). That's precisely what the Ralf's Phd thesis is about.
Now, the weird part: Rust doesn't contain full-blown dependent types system which can be used pervasively, it's complicated system is centered on lifetimes and soundness.
Which basically means that it's enough to prove that there are no UBs in safe Rust, but not enough to prove much beyond that.
That's still significantly different property from what C/C++ have. And very practically useful.
As for how all that is related to functional programming… it's, basically, impossible to say.
> it starts with a definition of "purely functional programming language" that is wrong?! (ML is not a purely functional programming language.)Who said it's “wrong?” Even Wikipedia's article on subject start with the exact difference between pure and impure functional programming is a matter of controversy sentence for crying out loud!
The big issue here is that reasonable people define “pureness” differently and then arrive at different conclusions.
Basically the best I can say about that link is… I couldn't say if he's even right or wrong because he talks about things which have not single “proper” definition.
