5 ms·
Zug does not attempt to solve memory safety. It aims to be a better C
by Kostarrr 2y ago
Zug does not attempt to solve memory safety. It aims to be a better C
- flohofwoe 2y agoA bit more nuance please, Zig doesn't attempt to solve compile-time memory safety like Rust does, but at least it provides spatial runtime memory safety (but also doesn't have a builtin solution for temporal memory safety - except a debug allocator which catches most use-after-free attempts on the heap) - so tl;dr: Zig is much better than C or C++ when it comes to memory safety, but isn't watertight like Rust.
- nikbackm 2y agoSo similar in that regard to Herb Sutter's experimental Cpp2 perhaps?