Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 322597

Summary: [clean up] "Remove unnecessary casts" should remove unnecessary parentheses
Product: [Eclipse Project] JDT Reporter: Markus Keller <markus.kell.r>
Component: UIAssignee: Deepak Azad <deepakazad>
Status: VERIFIED FIXED QA Contact:
Severity: normal    
Priority: P3 CC: daniel_megert, deepakazad
Version: 3.7   
Target Milestone: 3.7 M6   
Hardware: All   
OS: All   
Whiteboard:

Description Markus Keller CLA 2010-08-12 18:13:51 EDT
I20100810-0800

The "Remove unnecessary casts" Clean Up should remove unnecessary parentheses like the quick fix already does:

class IntComp implements Comparator<Integer> {
    public int compare(Integer o1, Integer o2) {
        return ((Integer) o1).intValue() - ((Integer) o2).intValue();
    }
}
Comment 1 Deepak Azad CLA 2011-02-20 23:27:08 EST
Fixed in HEAD (along with Bug 335173).
Comment 2 Markus Keller CLA 2011-02-25 10:54:09 EST
Verified in N20110224-2000, thanks. This was really annoying...