3 ms·
the point is that in FP languages, pattern matching uses closed ADTs, so you always know at compile time if you've covered all the cases.
by platz 8y ago
the point is that in FP languages, pattern matching uses closed ADTs, so you always know at compile time if you've covered all the cases.
- Dylan16807 8y agoHuh, you have do something with returning from a switch in typescript if you want it to make sure all cases are covered. So it's close but not quite there.