logoalt Hacker News

GuB-42 • yesterday at 12:44 AM • 2 replies • view on HN

Again, this would be missing the point of C.

While the philosophy of C++ is "C with extra features", and it certainly delivers on extra features, C is all about simplicity and compatibility.

You want to touch C as little as possible. There are who knows how many thousands of C compilers for obscure platforms and decades old legacy code that all depend on C being stable. The industry mostly leave C alone not because they don't have the resources, but because the world runs on C and they certainly don't want to break things that work!

If what you want is a simple, explicit language that is well suited for system and embedded programming while being more modern than C, there is Zig.

I like to say that Zig is to C what Rust is to C++.


Replies

uecker • yesterday at 1:01 AM

I agree that C should be stable, but my point was also not that it should change a lot. As one can see with Fil-C or with model checkers proving memory safety, a lot can be done even without changing it. Although Zig is nice, I really prefer C.

pjmlp • yesterday at 8:47 AM

> C is all about simplicity and compatibility.

Not paying that much attention at ISO C since 1989, right?