Bug 68825 - [compiler][1.5] detect not-exhaustive enum switches
Summary: [compiler][1.5] detect not-exhaustive enum switches
Status: VERIFIED FIXED
Alias: None
Product: JDT
Classification: Eclipse Project
Component: Core (show other bugs)
Version: 3.0   Edit
Hardware: PC Windows 2000
: P3 enhancement (vote)
Target Milestone: 3.1 M6   Edit
Assignee: Philipe Mulet CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2004-06-28 17:22 EDT by Adam Kiezun CLA
Modified: 2005-03-30 23:44 EST (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
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