News for hackers. Stuff that matters.
Re:Advancing Memory Safety by timschmidt on Wednesday October 16, 2024 @03:48AM (#41856602)
Yes, Rust does depend on Clang for the lowest level of compilation at the moment. MIR (where the borrow checker lives and most of memory safety is implemented) and HLR are both implemented in Rust.

What argument? Seems more like a misunderstanding to me.

Re:Advancing Memory Safety by pjmlp on Wednesday October 16, 2024 @05:18AM (#41857108)
Using your argument, Rust can't be fully trusted as long as its compilation model and runtime depends on having C++ somewhere.

In fact, that has broken Rust compilation semantics quite a few times already.

Re:Advancing Memory Safety by timschmidt on Wednesday October 16, 2024 @07:13AM (#41857783)
I don't think I've made any contradictory argument. Perhaps someone else did? Or maybe you assumed a binary where I see gradients. I'm quite sure I didn't claim anywhere that any language was perfectly memory safe. With Rust and Cheri we are getting closer, but there is still progress to be made.

I can say that Rust is well architected such that the borrow checker and most of memory safety is implemented in the midlevel intermediate representation, which is implemented using Rust, and the bits of Clang upon which MIR and HLR are built are both well tested by virtue of being used by multiple language frontends, and limited in scope and modularity. It'd be great to see an all-rust replacement though, as bugs in Clang have been found. I believe there are several projects in the works and existing pure-Rust bootstrap compilers sufficient to get the toolchain working.