Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

Sum types are much more than just error handling though. They can be used to describe any structure made of substructures, where you have _multiple kinds_ of substructures. The type of such a structure is the _sum_ of all the substructure types.


Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: