Bug 110773

Summary: ITypeBinding#isEqualTo(..) is wrong when comparing NodeList<String>.Cursor to its type declaration
Product: [Eclipse Project] JDT Reporter: Markus Keller <markus.kell.r>
Component: CoreAssignee: Olivier Thomann <Olivier_Thomann>
Status: VERIFIED FIXED QA Contact:
Severity: normal    
Priority: P3    
Version: 3.1.1   
Target Milestone: 3.2 M3   
Hardware: PC   
OS: Windows XP   
Whiteboard:

Description Markus Keller CLA 2005-09-27 06:00:03 EDT
M20050923-1430

public class NodeList<E> {
    class Cursor { }

    {
        NodeList<String>.Cursor cursor2;
    }
}

Use ITypeBinding#isEqualTo(..) to compare the type binding of
NodeList<String>.Cursor to the type binding of its declaration
(getTypeDeclaration(), or take the binding from the declaration class Cursor {}).

Expected: false
Is: true (in both directions)
Comment 1 Olivier Thomann CLA 2005-09-28 12:07:48 EDT
We had to compare the enclosing type as well for both bindings.
Comment 2 Olivier Thomann CLA 2005-09-28 12:16:21 EDT
Fixed and released in HEAD.
Regression test added in org.eclipse.jdt.core.tests.dom.ASTConverter15Test.test0198.
Comment 3 Frederic Fusier CLA 2005-10-30 07:23:34 EST
Verified for 3.2 M3 using build I20051025-0800+v_619