3 ms·
Given that Zig has functions which can return functions, maybe you could capture the top level io and allocator and return a struct with a bunch of functions th
by vjerancrnjak 11mo ago
Given that Zig has functions which can return functions, maybe you could capture the top level io and allocator and return a struct with a bunch of functions that now have the top scope io and allocator visible.
Don’t know.
That’s how people usually get rid of repeat arguments (or OOP constructor).