3 ms·
Go repeating the billion dollar mistake. Why am I not surprised...
by valenterry 2y ago
Go repeating the billion dollar mistake. Why am I not surprised...
- ajb 2y agoThinking about it, it's not obviously worth making sum types non-nillable unless you also figure out a comprehensive nil-free solution for the rest of the language. Because if you include any interface in your sum, that branch will be nillable anyway. So you might as well check for nil only once at the base case, rather than on each branch.