Hacker News new | ask | show | jobs
by painful 2686 days ago
How about people stop using unsafe languages such as C and C++?
4 comments

Rust without the use of unsafe code is considered by most to be a safe language but nonetheless, it's still useful to fuzz it to find logic bugs (like assert failures) or anything that triggers a panic (like out of bound array access or integer overflow).

More info: https://github.com/rust-fuzz

Disclaimer: I am the author of the rust fuzzer honggfuzz-rs.

What planet do you live on? What do you think embedded/realtime systems, signal processing, graphics, and kernel developers are supposed to use? Also, what do you think these memory-safe, garbage collected, runtime environments are written in?
> What do you think embedded/realtime systems, signal processing, graphics, and kernel developers are supposed to use?

My guess is that they'd use Rust for new code.

Rust doesn't yet support every platform that C supports and training staff to use a new language and adding tooling to integrate a new language into an existing codebase is extremely expensive.
I don't even know Rust, so there's a reason I write low-level stuff like that in C/C++ ;)
Fuzzing is effective for more than finding memory related bugs. Parsing related crashed, code injection, unexpected state machine path can all also be revealed.

Beside, as much I agree with the benefits of a memory safe language, and I do believe in the urgency of promoting techs like rust, C and C++ are going to be part of our lifes for a lot of time.

If you gotta use knife, make sure you have the tools to make it sharp.

Even if everyone switched to writing Rust/Swift/$SAFE_LANGUAGE today, there are many, many projects that are written in C/C++ that aren't going to disappear overnight.