4 ms·
I think because if you're building with a language that's extremely interface oriented you probably don't want to think "if it's this type, do x, if it's that t
by staticassertion 5y ago
I think because if you're building with a language that's extremely interface oriented you probably don't want to think "if it's this type, do x, if it's that type do y" manually. Instead that would be another job for another interface. But I think that's more a symptom of having a powerful hammer than actually designing well, and sum types solve a different problem than interfaces.