Need option types #6
Loading…
Reference in New Issue
Block a user
No description provided.
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
No idea why it took me until now to figure this out, but we need them. There are three options:
First option is bone-headed because if you have a table of like 16 optional integers, that's potentially 16+ allocs for what could just be a flat struct. That's not to mention the (albeit minor) performance penalty incurred due to pointer indirection when using the data.
Second option is still not ideal because that hardwires a completely different module into this one's public API, but it isn't without precedent, and go-util is used everywhere in holanet anyway. The intention was for it to be an extension to the standard library, so perhaps it's time to really lean into that.
Third option isn't all that different from the second because an alias is really, really thin. It would mean one less package to import, though, which is good.
Fourth option is so stupid. This would make two competing option types within holanet and I am the only person in holanet so that isn't even remotely productive.
Thinking of the third.
Need to find out how this would work in PDL as well. Why not copy Zig:
Hmm, we would need to avoid parsing this as part of the pair type, it must be parsed as part of the table pair itself. This is because it doesn't really mean anything outside of the context of a table, not even within an OTA.