3 ms·
> C/C++ can be made memory safe .. but it's much harder to prove your work is memory safe. sel4 is memory safe C, for example. The safety is achieved by a larg
by pjc50 3y ago
> C/C++ can be made memory safe
.. but it's much harder to prove your work is memory safe. sel4 is memory safe C, for example. The safety is achieved by a large external theorem prover and a synced copy written in Haskell. https://github.com/seL4/l4v https://github.com/seL4/l4v
Typechecks are form of proof. It's easier to write provably safe Rust than provably safe C because the proofs and checker are integrated.
- bayindirh 3y agoI have never claimed that it's easy. I said doing it is simple, and prone to errors, and needs to be verified either by design or tests, ideally both. I'm aware of seL4. They're doing an amazing job of verifying what they have written. However, why I'm is so adamant is because I have done something similar myself, albeit in a weaker form, but at least I verified that every part of my code is not doing funny things by vigorously testing it in valgrind in different scenarios both in units and end to end. Again, I'm not against Rust. I'm against vilifying languages.
- throwaway2037 3y agoC++ uber fan here. > C/C++ can be made memory safe > I have never claimed that it's easy. So... you didn't say much. I can rewrite your sentence with assembler or machine code. Again, not much said.
- bayindirh 3y agoI have actually said so much more around the thread. Maybe you should give a look at them.