Bug 136095

Summary: Type Hierarchy incomplete with illegally parameterized superinterfaces
Product: [Eclipse Project] JDT Reporter: Markus Keller <markus.kell.r>
Component: CoreAssignee: Jerome Lanneluc <jerome_lanneluc>
Status: VERIFIED FIXED QA Contact:
Severity: normal    
Priority: P3 CC: jerome_lanneluc
Version: 3.2   
Target Milestone: 3.2 RC2   
Hardware: PC   
OS: Windows XP   
Whiteboard:
Attachments:
Description Flags
Proposed patch and regression test
none
Improved patch and regression tests none

Description Markus Keller CLA 2006-04-11 08:11:42 EDT
N20060411-0010

Type Hierarchy on Klass:
-------------
interface Ints extends List<Integer> {}
abstract class Klass implements List<String>, Ints {}
-------------

In N20060407-0010, the supertypes of Klass were Object, Ints and List<E>.
In N20060411-0010, the sypertypes are only Object and List<E>.

I think the type hierarchy should not care about the validity of the supertypes' type arguments and always include all declared supertypes.

This change broke our test ChangeTypeRefactoringTests.test4TypeParameters.
Comment 1 Jerome Lanneluc CLA 2006-04-12 10:49:14 EDT
Created attachment 38408 [details]
Proposed patch and regression test
Comment 2 Markus Keller CLA 2006-04-25 13:48:36 EDT
Could you release the patch such that we can enable our test again?
Comment 3 Philipe Mulet CLA 2006-04-26 07:18:58 EDT
+1 for 3.2RC2
Comment 4 Jerome Lanneluc CLA 2006-04-26 09:08:09 EDT
Created attachment 39518 [details]
Improved patch and regression tests
Comment 5 Jerome Lanneluc CLA 2006-04-26 09:09:37 EDT
Released improved pacth and regression tests
Comment 6 Jerome Lanneluc CLA 2006-04-26 10:38:31 EDT
*** Bug 136307 has been marked as a duplicate of this bug. ***
Comment 7 Markus Keller CLA 2006-04-26 12:07:44 EDT
The fix in HEAD seems to fix only the type hierarchy, but not type bindings. In M6, getInterfaces() of the type binding for Klass returned:
  0: java.util.List<java.lang.String>
  1: xy.Ints

, but with HEAD, I only get
  0: java.util.List<java.lang.String>

I would expect that both hierarchies are consistent. Shall I open a new bug or do you want to reopen this one? Our (disabled) test still fails.
Comment 8 Jerome Lanneluc CLA 2006-04-26 12:19:20 EDT
If you're talking about the DOM AST ITypeBinding#getInterfaces(), yes please open a separate bug report.
Comment 9 Markus Keller CLA 2006-04-26 12:49:38 EDT
Opened bug 138671 for comment 7.
Comment 10 Olivier Thomann CLA 2006-04-28 14:06:07 EDT
Verified with I20060427-1600 for 3.2RC2