Hacker News new | ask | show | jobs
by Comevius 1456 days ago
Some people think Rust is the best programming language for everything from embedded to web browsers, it's sweet spot however really is replacing C++.

Zig's sweet spot is C, and it really helps that it was made to extend C, not completely replace it.

2 comments

This stance is kinda countered by actual events, i.e. Rust becoming a 2nd class citizen in possibly the most famous C project right now: Linux.
I wonder if it is actually already possible to write Linux device drivers in Zig without any "publicity fanfare", because of how easy Zig integrates with C projects and Zig's explicit approach to memory management.
That might be, but they still wouldn't let Zig code into the main tree without such fanfare.
Rust is also pushed by Microsoft for the same. I guess the motivation is that you can effectively quarantine unsafe code with it, but people will bend over backwards to use it, and the project managers are being convinced that Rust is inherently safe. If Rust automagically stops you from writing shit code you can also hire shit coders for cheap. Throw GitHub Copilot on the pile and the future of software development is here.
That's just Zig flavoured EEE.
I don't really think that Andrew Kelley and his tiny non-profit have those kind of ambitions, or really if it would matter if they would. C is the lingua franca, there is no extinguishing it.

These guys genuinely just want to make a practical, simple, common sense system programming language that let's you talk to the hardware, the operating system, and shovel bits around conveniently.