Bug 264491

Summary: JDT-Compiler buggy since 3.5Mx
Product: [Eclipse Project] JDT Reporter: Joerg Hohwiller <joerg>
Component: CoreAssignee: Kent Johnson <kent_johnson>
Status: CLOSED DUPLICATE QA Contact:
Severity: normal    
Priority: P5    
Version: 3.5   
Target Milestone: 3.5 RC1   
Hardware: PC   
OS: Windows XP   
URL: http://m-m-m.svn.sourceforge.net/svnroot/m-m-m/trunk/mmm-util/mmm-util-core/src/main/java/net/sf/mmm/util/collection/base/AbstractTreeNode.java
Whiteboard:
Attachments:
Description Flags
Code to prove the bug none

Description Joerg Hohwiller CLA 2009-02-11 04:47:17 EST
Build ID: I20090202-1535

Steps To Reproduce:
1. Create a generic interface with a method returning a type variable

2. Create a generic interface that extends the above interface and specializes the generic type and overrides the method

3. Implement the specific interface and use the method
4. compile your code

With Eclipse 3.5M4/M5 you will get
"The method ... is ambiguous for the type ..."
With Eclipse 3.4 or Sun javac compilation succeeds


More information:
See Line 72 (this.mutableChildList = listFactory.create();)
of this file as example:

http://m-m-m.svn.sourceforge.net/svnroot/m-m-m/trunk/mmm-util/mmm-util-core/src/main/java/net/sf/mmm/util/collection/base/AbstractTreeNode.java
Comment 1 Kent Johnson CLA 2009-02-24 14:23:34 EST
Please provide a complete reproduceable testcase.

I tried to duplicate given the instructions but it worked fine.

thanks
Comment 2 Kent Johnson CLA 2009-03-05 11:08:49 EST
Waiting for a complete testcase
Comment 3 Joerg Hohwiller CLA 2009-05-03 15:57:03 EDT
Created attachment 134184 [details]
Code to prove the bug

Maybe my textual description was too imprecise. However the linked code proves the bug. Anyways here you have an isolated showcase with just 3 java-files.
The method createGeneric() can also be removed - just to give the code some sense...
Comment 4 Kent Johnson CLA 2009-05-04 10:52:16 EDT
Thanks for the testcase

I reproduced the ambiguous error with 3.5M4 but no error is produced with 3.5M7.

Removed the patch for bug 268837 & the error appeared in M7

*** This bug has been marked as a duplicate of bug 268837 ***
Comment 5 Joerg Hohwiller CLA 2009-05-08 17:42:28 EDT
jup. I retested this with M7 and after cleaning and rebuilding my project, everything compiles properly. Thanks!
BTW - therefore I now get warnings for using raw types e.g. in case of "... instanceof Class" and I should do "... instanceof Class<?>" - this is nuts.
Besindes now javadoc-links on packages are considered as invalid.