4 ms·
> Modern enums in languages with powerful compilers are one of my favourite features and I repeatedly find them to be a marker of high quality codebases. Mega
by omegalulw 5y ago
> Modern enums in languages with powerful compilers are one of my favourite features and I repeatedly find them to be a marker of high quality codebases.
Mega +1. I LOLed when I saw the post. My favorite feature of enums is that you limit the set of values - and thus get a lot of free checks. Not to mention being able to write case statements without default - which catches future bugs (C++).
- selfhoster11 5y agoCould you explain what you found so funny? IMO, there are real benefits to "smart" enums, especially with respect to reverse lookups.