Zig is relative new young language - latest verion 0.14.0 (2024-11-05).
Zig is not going to replace C - the main goal is to work together:
Currently it is pragmatically true that C is the most versatile and portable language. Any language that does not have the ability to interact with C code risks obscurity. Zig is attempting to become the new portable language for libraries by simultaneously making it straightforward to conform to the C ABI for external functions, and introducing safety and language design that prevents common bugs within the implementations. Why Zig ...
...established teams are not adopting Rust...The teams that are using C are very interested in moving to C++. C++ adoption makes sense because it’s a modern language that allows teams to leverage the intellectual property they’ve already developed.
I absolutly disagree with the usage of C++ instead of C.
Zig adoption makes sense because it’s a modern language that allows teams to leverage the intellectual property they’ve already developed.
Adree 100%
What will this give to OpenWRT?
New developers ("fresh blood") , because developing on
open source
embedded linux
using modern language
is funny
Does OpenWRT community need such innovation?
CLARIFICATION - i am talking about user space(application) development
It’s always exciting to see new programming languages like Zig. But you have to ask what value it actually adds to an ecosystem like OpenWRT.
Sure, you can write add-on packages or toolchain support in any language, but for the Linux kernel itself, it’s all about C and possibly Rust in the future. But even then, Rust will only be used for device drivers and possibly loadable kernel modules.
Yeah, for user-space development, it should work just fine, like any other programming language. As for Rust in the Linux kernel, it's still a work in progress:
I personally think Zig doesn't really have enough market share to make me personally consider it. It is still pretty new and I would be careful to jump on it to fast.
If you are looking for a C alternative I would go full Rust. The end binaries are big but you can strip them down. Also it is very performant and comparable to C in most cases. Rust also has the advantage of being very popular which means there are going to be a lot more help resources.
What zig has to do with rust? The article you refer to looks like glued together paragraphs. Openwrt is decades behind adopting java. What would you do about it?