Bug 77211 - [1.5][enum] abstract enum requires invalid 'abstract enum' declaration
Summary: [1.5][enum] abstract enum requires invalid 'abstract enum' declaration
Status: RESOLVED DUPLICATE of bug 78916
Alias: None
Product: JDT
Classification: Eclipse Project
Component: Core (show other bugs)
Version: 3.1   Edit
Hardware: PC Linux
: P3 normal (vote)
Target Milestone: 3.1 M4   Edit
Assignee: Philipe Mulet CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2004-10-28 12:25 EDT by jp fielding CLA
Modified: 2004-12-09 18:26 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 jp fielding CLA 2004-10-28 12:25:16 EDT
enums are allowed to have abstract method signatures, but the enum cannot be
declared abstract.  eclipse currently requires this, javac chokes
Comment 1 jp fielding CLA 2004-10-28 16:18:30 EDT
an example:

public enum StopLight{
    RED{
        public StopLight next(){ return GREEN; }
    },
    GREEN{
        public StopLight next(){ return YELLOW; }
    },
    YELLOW{
        public StopLight next(){ return RED; }
    };

   public abstract StopLight next();
}
Comment 2 Philipe Mulet CLA 2004-12-09 18:22:23 EST
Testcase is now properly supported.
Comment 3 Philipe Mulet CLA 2004-12-09 18:26:02 EST
Test: EnumTest#test048

*** This bug has been marked as a duplicate of 78916 ***