I think Zig is hard...but worth it
DRANK

Depending on your background, you might also not be used to having to think in terms of exact numeric types (u8, i16, f64, etc.) for every single runtime value in your program. Handling "strings" means dealing with pointers, sentinel termination, arrays, and slices. This will slow you down very quickly if you’re used to dynamic languages which (very conveniently) handle these details for you.If you’re new to manual memory management, you already have a pretty big hurdle to get over.That’s true regardless of language.But Zig throws another level of decision-making at you that (most?) developers are rarely asked to make: Choosing a memory allocation strategy.And you won’t get far without making a decision. A significant portion of the Zig standard library requires that you provide an allocator.That’s a heck of a thing to ask of a beginner!Why that’s good: This is actually one of the coolest things about Zig. To write performant software (or even just as a learning exercise), we sh…

ratfactor.com
Related Topics:
1 comments