News for hackers. Stuff that matters.
Re:Committing to Rust for Kernel Code by charcircuit on Thursday November 23, 2023 @01:57PM (#38396165)
gcc is programmed in C++ too. The language of the compiler doesn't matter. What matters is C makes it too easy to make memory errors which Rust protects you from. This is why Linux should migrate to Rust and you can see this migration starting with adding support for Rust based drivers.
Re:Committing to Rust for Kernel Code by ziandrome22 on Thursday November 23, 2023 @02:10PM (#38396295)
I disagree that the language of the compiler doesn't matter. It absolutely matters in some cases, all of which are cases where (ANSI) C is pretty much the only option because of the inherent difficulty of C++ compilers.
Re:Committing to Rust for Kernel Code by singingboyo on Thursday November 23, 2023 @02:44PM (#38396697)
This still doesn't explain why the language of the compiler matters. I could write a C compiler in Pony-lang targeting a 30-year-old MCU were I so inclined.

The available compilers targeting your microcontroller certainly matter, though. You certainly still find lots of options that aren't Rust-compatible, but a non-trivial number microcontrollers are ARM or RISC-V based now, and can be targeted by LLVM/Rust.

Re:Committing to Rust for Kernel Code by nemothekid on Thursday November 23, 2023 @02:25PM (#38396465)
What target are you compiling to that gcc doesn't support?
Re:Committing to Rust for Kernel Code by rileymat2 on Thursday November 23, 2023 @07:57PM (#38399618)
Typically if this is the case, won't you be cross compiling for that target anyway?