Buggy code:
protected IType focusType ; protected ICompilationUnit [ ] workingCopies ; protected Map classToSuperclass ; protected Map typeToSuperInterfaces ; protected Map typeToSubtypes ; protected Map typeFlags ; protected TypeVector rootClasses = new TypeVector ( ) ; protected ArrayList interfaces = new ArrayList ( 10 ) ; public ArrayList missingTypes = new ArrayList ( 4 ) ; protected static final IType [ ] NO_TYPE = new IType [ 0 ] ; protected IProgressMonitor progressMonitor = null ; protected ArrayList changeListeners = null ; public Map files = null ; protected Region packageRegion = null ; protected Region projectRegion = null ; protected boolean computeSubtypes ; IJavaSearchScope scope ; public boolean needsRefresh = true ; protected ChangeCollector changeCollector ; public TypeHierarchy ( ) { } public TypeHierarchy ( IType type , ICompilationUnit [ ] workingCopies , IJavaProject project , boolean computeSubtypes ) { } public TypeHierarchy ( IType type , ICompilationUnit [ ] workingCopies , IJavaSearchScope scope , boolean computeSubtypes ) { } protected void initializeRegions ( ) { } private void addAllCheckingDuplicates ( ArrayList list , IType [ ] collection ) { } protected void addInterface ( IType type ) { } protected void addRootClass ( IType type ) { } protected void addSubtype ( IType type , IType subtype ) { } public synchronized void addTypeHierarchyChangedListener ( ITypeHierarchyChangedListener listener ) { } private static Integer bytesToFlags ( byte [ ] bytes ) { } public void cacheFlags ( IType type , int flags ) { } protected void cacheSuperclass ( IType type , IType superclass ) { } protected void cacheSuperInterfaces ( IType type , IType [ ] superinterfaces ) { } protected void checkCanceled ( ) { } protected void compute ( ) throws CoreException , JavaModelException { } public boolean contains ( IType type ) { } public void elementChanged ( ElementChangedEvent event ) { } public boolean exists ( ) { } public void fireChange ( ) { } private static byte [ ] flagsToBytes ( Integer flags ) { } public IType [ ] getAllClasses ( ) { } public IType [ ] getAllInterfaces ( ) { } public IType [ ] getAllSubtypes ( IType type ) { } private IType [ ] getAllSubtypesForType ( IType type ) { } private void getAllSubtypesForType0 ( IType type , ArrayList subs ) { } public IType [ ] getAllSuperclasses ( IType type ) { } public IType [ ] getAllSuperInterfaces ( IType type ) { } private void getAllSuperInterfaces0 ( IType type , ArrayList supers ) { } public IType [ ] getAllSupertypes ( IType type ) { } private void getAllSupertypes0 ( IType type , ArrayList supers ) { } public IType [ ] getAllTypes ( ) { } public int getCachedFlags ( IType type ) { } public IType [ ] getExtendingInterfaces ( IType type ) { } private IType [ ] getExtendingInterfaces0 ( IType extendedInterface ) { } public IType [ ] getImplementingClasses ( IType type ) { } private IType [ ] getImplementingClasses0 ( IType interfce ) { } public IType [ ] getRootClasses ( ) { } public IType [ ] getRootInterfaces ( ) { } public IType [ ] getSubclasses ( IType type ) { } public IType [ ] getSubtypes ( IType type ) { } private IType [ ] getSubtypesForType ( IType type ) { } public IType getSuperclass ( IType type ) { } public IType [ ] getSuperInterfaces ( IType type ) { } public IType [ ] getSupertypes ( IType type ) { } public IType getType ( ) { } protected IType [ ] growAndAddToArray ( IType [ ] array , IType [ ] additions ) { } protected IType [ ] growAndAddToArray ( IType [ ] array , IType addition ) { } public boolean hasFineGrainChanges ( ) { } private boolean hasSubtypeNamed ( String simpleName ) { <START_BUG> if ( this . focusType . getElementName ( ) . equals ( simpleName ) ) { <END_BUG> return true ; } IType [ ] types = this . getAllSubtypes ( this . focusType ) ; for ( int i = 0 , length = types . length ; i < length ; i ++ ) { if ( types [ i ] . getElementName ( ) . equals ( simpleName ) ) { return true ; } } return false ; } private boolean hasTypeNamed ( String simpleName ) { } boolean includesTypeOrSupertype ( IType type ) { } protected void initialize ( int size ) { } public synchronized boolean isAffected ( IJavaElementDelta delta ) { } private boolean isAffectedByChildren ( IJavaElementDelta delta ) { } private boolean isAffectedByJavaModel ( IJavaElementDelta delta , IJavaElement element ) { } private boolean isAffectedByJavaProject ( IJavaElementDelta delta , IJavaElement element ) { } private boolean isAffectedByPackageFragment ( IJavaElementDelta delta , IJavaElement element ) { } private boolean isAffectedByPackageFragmentRoot ( IJavaElementDelta delta , IJavaElement element ) { } protected boolean isAffectedByOpenable ( IJavaElementDelta delta , IJavaElement element ) { } private boolean isInterface ( IType type ) { } public IJavaProject javaProject ( ) { } protected static byte [ ] readUntil ( InputStream input , byte separator ) throws IOException , JavaModelException { } protected static byte [ ] readUntil ( InputStream input , byte separator , int offset ) throws IOException , JavaModelException { } public static ITypeHierarchy load ( IType type , InputStream input , WorkingCopyOwner owner ) throws JavaModelException { } protected boolean packageRegionContainsSamePackageFragment ( IJavaElement element ) { } public synchronized void refresh ( IProgressMonitor monitor ) throws JavaModelException { } public synchronized void removeTypeHierarchyChangedListener ( ITypeHierarchyChangedListener listener ) { } public void store ( OutputStream output , IProgressMonitor monitor ) throws JavaModelException { } boolean subtypesIncludeSupertypeOf ( IType type ) { } public String toString ( ) { } private void toString ( StringBuffer buffer , IType type , int indent , boolean ascendant ) { } boolean hasSupertype ( String simpleName ) { } protected void worked ( int work ) { }

Fix:
if ( ( ( this . focusType ) != null ) && ( this . focusType . getElementName ( ) . equals ( simpleName ) ) ) {