Bug 51867

Summary: An anonymous type is missing in type hierarchy when editor is modified
Product: [Eclipse Project] JDT Reporter: David Audel <david_audel>
Component: CoreAssignee: Jerome Lanneluc <jerome_lanneluc>
Status: VERIFIED FIXED QA Contact:
Severity: normal    
Priority: P3    
Version: 3.0   
Target Milestone: 3.0 M9   
Hardware: PC   
OS: Windows 2000   
Whiteboard:

Description David Audel CLA 2004-02-12 12:27:36 EST
build 20040212

1) create the following classes
package q1;
public class X {
  Object x = new Y(){};
}
package q1;
public class Y {
}
2) select 'q1' in package explorer
3) do right click and Open Type Hierarchy
Hierachy view contains
Object
+-X
+-Y
  +-newY(){..}
4) cut 'Object x =' and save
Hierachy view contains
Object
+-X
+-Y
5) copy 'Object x =' and save
Hierachy view contains
Object
+-X
+-Y

The anonymous class is missing
Comment 1 Jerome Lanneluc CLA 2004-04-05 08:52:46 EDT
Step 5 should read: paste 'Object x =' and save
Comment 2 Jerome Lanneluc CLA 2004-04-05 10:55:15 EDT
Changed TypeHierarchy.hasSubtypeNamed(String) to look in all types of the 
hierarchy if the focus is null.

Added regression test TypeHierachyNotificationTests.testAddAnonymousTypeInRegion
()
Comment 3 Frederic Fusier CLA 2004-05-18 11:00:24 EDT
Verified for 3.0 with build I200405180816.