Comment by jamiejquinn
3 months ago
Snap! I also played around with closures a tonne in Zig. Definitely possible but not... ergonomic. Haven't ended up using them much.
And agree with allocators; in C I always considered using custom allocators but never really needed to. Having them just available in the zig std means I actually use them. The testing allocator is particularly useful IMO.
Never used Go but if it's Zig-like I might give it a shot! Thanks!
I'll make a list of the things that both languages have in common that make them feel similar to me:
[0] https://ziglang.org/documentation/master/std/#std.Io.async
[1] https://go.dev/tour/concurrency/1
[2] https://ziglang.org/documentation/master/std/#std.Io.Queue
[3] https://go.dev/tour/concurrency/2
[4] https://ziglang.org/documentation/master/std/#std.Io.select
[5] https://go.dev/tour/concurrency/5