News for hackers. Stuff that matters.
Re:Is your programming language unreasonable? (2015) by eyelidlessness on Saturday October 10, 2020 @07:16PM (#24742612)
> Do most (or any) languages in which people take this approach actually enforce handling of all cases? Or could a programmer write that this way: [...]

Any language that provides this sort of union type will error in some way if you try to access something that isn’t guaranteed to be on every type in the union. Some languages which support null checking will infer Customer to be nullable.

There are no comments on this comment yet.