Re:Tagged Unions Are Overrated
by contravariant on Friday February 19, 2021 @09:34AM
(#26193540)
I'm not sure if exhaustiveness is that useful. Rather than forcing the people who use the data-type to keep track of any changes you instead force anyone who changes the data-type to keep track of any place where it is used. If you automatically enforce exhaustiveness then you either need to freeze all your public data-types or turn every update into a breaking change.
[ Parent
| on HN ]