Hacker News new | past | comments | ask | show | jobs | submit login

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.



But the flag affects all switches on enums.




Consider applying for YC's W25 batch! Applications are open till Nov 12.

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

Search: