4 ms·
I'm learning zig myself after several years of doing rust and golang (I still use golang a lot). I particularly like the quote >"Because even if you and I both
by gabereiser 4y ago
I'm learning zig myself after several years of doing rust and golang (I still use golang a lot).
I particularly like the quote >"Because even if you and I both know how to write memory safe C, it’s very hard for us to have an interface boundary where we can agree about who does what."
This is still a huge issue in many domains, in many languages. Do you throw the contract out the window on responsibility because you lean on your GC? Or do you make it explicit on who owns what when you don't have a GC. If I allocate a struct as part of my ABI to give to you, the application developer, am I clear on who's responsible for freeing the struct? Do I provide a function for that or do I call it out as gospel for using the library? I wish we didn't have to have these fights.