[ prog / sol / mona ]

prog


Go vs Rust

20 2023-12-28 21:23

>>19
Sure, why not Zig?

Much like Go, Zig is intended to be simple, to compile fast, and to make async programming as seamless as possible. It eschews "traditional" generics in favor of Lisp-style compile time code generation. It's worth noting Go never had very good code generation tools and recently went in the opposite direction by adding generics.

Much like Rust, Zig is designed to be a safer alternative to C in the same niche (GCless systems programming) and even to coexsit with C during an incremental rewrite of existing C code. Unlike Rust, Zig has designed all its tooling with such rewrites in mind, and works great for building pure C codebases, so that your first step in such a rewrite might be to replace your makefiles and C compiler with the Zig build system.

Unlike either of them, Zig is designed with an eye towards bootstrapping itself on new platforms instead of relying on cross compilation, because I guess there's a chance all computers will be vaporized by a solar flare tomorrow and we'll have to rebuild the entire software ecosystem out of duct tape and bubblegum.

37


VIP:

do not edit these