Better HN
top
new
best
ask
show
jobs
Log in
Sign up
Better HN
Comment
by
minexew
· 9y ago · 0 comments
I should have clarified more; you'd use this for switches where you need to always handle all cases. Then if a you add a new value to the enum but forget to update the switch, you get a compile-time error instead of a buggy program.
Comments
[–]
asveikau
9y ago
But the flag affects all switches on enums.