KnowledgeHub
Questions
Tags
Users
Search
Alex Rivera
|
Logout
Edit Question
Title
Body
Why does the following code fail to compile, while changing the case statement to case ENUM1: doSomeStuff(); works? public enum EnumType { ENUM1, ENUM2, ENUM3; void doSomeStuff() { switch(this) { case EnumType.ENUM1: doSomeStuff(); } } }
Tags (comma-separated)
Save Edits
Cancel