Bug 68825

Summary: [compiler][1.5] detect not-exhaustive enum switches
Product: [Eclipse Project] JDT Reporter: Adam Kiezun <akiezun>
Component: CoreAssignee: Philipe Mulet <philippe_mulet>
Status: VERIFIED FIXED QA Contact:
Severity: enhancement    
Priority: P3    
Version: 3.0   
Target Milestone: 3.1 M6   
Hardware: PC   
OS: Windows 2000   
Whiteboard:

Description Adam Kiezun CLA 2004-06-28 17:22:00 EDT
3.0
switches on enums should be exhaustive - if they're not, we should show a warning
Comment 1 Philipe Mulet CLA 2005-02-27 22:23:25 EST
# Added optional compiler diagnosis to flag incomplete enum switch statements.
Corresponding problem ID is: IProblem.MissingEnumConstantCase

* COMPILER / Reporting Incomplete Enum Switch
*    When enabled, the compiler will issue an error or a warning whenever an
enum constant has
*    no corresponding case label in an enum switch statement
*    type has no case label matching an enum constant.
*     - option id:       
"org.eclipse.jdt.core.compiler.problem.incompleteEnumSwitch"
*     - possible values:   { "error", "warning", "ignore" }
*     - default:           "ignore"

Fixed
Comment 2 Olivier Thomann CLA 2005-03-30 23:44:37 EST
Verified in 20050330-0500