Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

I write a lot of C and I've used Rust a fair amount. And to sum up my experience, I definitely think that Rust is a decent language on its own, but it has several issues that make it unsuited for the low-level code that it wants to replace. And in my opinion, this has largely come about because I don't really think many of the people involve really came from a C background, and as a result most of the stuff I see being done with it really isn't stuff that would have been written in C in the first place - and if it was, it could have already been written in several different languages (Like the coreutils). For the low-level pieces of code like kernels, Rust is lacking a lot of little things - things that, had being a C replacement been a core focus, would have never slipped through. As it is, some of these features have been added in recently, but they're in `nightly` and may very well change or get removed.

And with that, the safety of Rust is (IMO) overstated - the distinction between `unsafe` and `safe` is not a very good way to judge safety. I wrote a lot about this here[0].

All that said though, there are also lots of things I liked about Rust. In particular I found slices to be something I really wish was in C, they basically just solidify the normal way you do things in C, and it then allows the compiler do things like bounds checking. The `enum` system is also fairly nice.

[0] https://www.reddit.com/r/programming/comments/6f235k/rewrite...



Consider applying for YC's Winter 2026 batch! Applications are open till Nov 10

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: