Buggy code:
protected StringSet simpleStrings ; protected SimpleLookupTable secondaryTypesToRemove ; protected boolean hasStructuralChanges ; protected int compileLoop ; public static int MaxCompileLoop = 5 ; protected IncrementalImageBuilder ( JavaBuilder javaBuilder ) { } public boolean build ( SimpleLookupTable deltas ) { } protected void addAffectedSourceFiles ( ) { } protected void addDependentsOf ( IPath path , boolean isStructuralChange ) { } protected void cleanUp ( ) { } protected boolean findAffectedSourceFiles ( IResourceDelta delta , ClasspathLocation [ ] classFoldersAndJars , IProject prereqProject ) { } protected void findAffectedSourceFiles ( IResourceDelta binaryDelta , int segmentCount , StringSet structurallyChangedTypes ) { } protected boolean findSourceFiles ( IResourceDelta delta ) throws CoreException { } protected void findSourceFiles ( IResourceDelta sourceDelta , ClasspathMultiDirectory md , int segmentCount ) throws CoreException { IResource resource = sourceDelta . getResource ( ) ; boolean isExcluded = ( ( ( md . exclusionPatterns ) != null ) || ( ( md . inclusionPatterns ) != null ) ) && ( Util . isExcluded ( resource , md . inclusionPatterns , md . exclusionPatterns ) ) ; switch ( resource . getType ( ) ) { case IResource . FOLDER : if ( isExcluded && ( ( md . inclusionPatterns ) == null ) ) return ; switch ( sourceDelta . getKind ( ) ) { case IResourceDelta . ADDED : if ( ! isExcluded ) { IPath addedPackagePath = resource . getFullPath ( ) . removeFirstSegments ( segmentCount ) ; createFolder ( addedPackagePath , md . binaryFolder ) ; if ( JavaBuilder . DEBUG ) System . out . println ( ( "Found<seq2seq4repair_space>added<seq2seq4repair_space>package<seq2seq4repair_space>" + addedPackagePath ) ) ; addDependentsOf ( addedPackagePath , true ) ; } case IResourceDelta . CHANGED : IResourceDelta [ ] children = sourceDelta . getAffectedChildren ( ) ; for ( int i = 0 , l = children . length ; i < l ; i ++ ) findSourceFiles ( children [ i ] , md , segmentCount ) ; return ; case IResourceDelta . REMOVED : if ( isExcluded ) { children = sourceDelta . getAffectedChildren ( ) ; for ( int i = 0 , l = children . length ; i < l ; i ++ ) findSourceFiles ( children [ i ] , md , segmentCount ) ; return ; } IPath removedPackagePath = resource . getFullPath ( ) . removeFirstSegments ( segmentCount ) ; if ( ( sourceLocations . length ) > 1 ) { for ( int i = 0 , l = sourceLocations . length ; i < l ; i ++ ) { if ( sourceLocations [ i ] . sourceFolder . getFolder ( removedPackagePath ) . exists ( ) ) { createFolder ( removedPackagePath , md . binaryFolder ) ; IResourceDelta [ ] removedChildren = sourceDelta . getAffectedChildren ( ) ; for ( int j = 0 , m = removedChildren . length ; j < m ; j ++ ) findSourceFiles ( removedChildren [ j ] , md , segmentCount ) ; return ; } } } IFolder removedPackageFolder = md . binaryFolder . getFolder ( removedPackagePath ) ; if ( removedPackageFolder . exists ( ) ) removedPackageFolder . delete ( IResource . FORCE , null ) ; if ( JavaBuilder . DEBUG ) System . out . println ( ( "Found<seq2seq4repair_space>removed<seq2seq4repair_space>package<seq2seq4repair_space>" + removedPackagePath ) ) ; addDependentsOf ( removedPackagePath , true ) ; newState . removePackage ( sourceDelta ) ; } return ; case IResource . FILE : if ( isExcluded ) return ; String resourceName = resource . getName ( ) ; <START_BUG> if ( org . eclipse . jdt . internal . compiler . util . Util . isJavaFileName ( resourceName ) ) { <END_BUG> IPath typePath = resource . getFullPath ( ) . removeFirstSegments ( segmentCount ) . removeFileExtension ( ) ; String typeLocator = resource . getProjectRelativePath ( ) . toString ( ) ; switch ( sourceDelta . getKind ( ) ) { case IResourceDelta . ADDED : if ( JavaBuilder . DEBUG ) System . out . println ( ( "Compile<seq2seq4repair_space>this<seq2seq4repair_space>added<seq2seq4repair_space>source<seq2seq4repair_space>file<seq2seq4repair_space>" + typeLocator ) ) ; sourceFiles . add ( new SourceFile ( ( ( IFile ) ( resource ) ) , md , true ) ) ; String typeName = typePath . toString ( ) ; if ( ! ( newState . isDuplicateLocator ( typeName , typeLocator ) ) ) { if ( JavaBuilder . DEBUG ) System . out . println ( ( "Found<seq2seq4repair_space>added<seq2seq4repair_space>source<seq2seq4repair_space>file<seq2seq4repair_space>" + typeName ) ) ; addDependentsOf ( typePath , true ) ; } return ; case IResourceDelta . REMOVED : char [ ] [ ] definedTypeNames = newState . getDefinedTypeNamesFor ( typeLocator ) ; if ( definedTypeNames == null ) { removeClassFile ( typePath , md . binaryFolder ) ; if ( ( ( sourceDelta . getFlags ( ) ) & ( IResourceDelta . MOVED_TO ) ) != 0 ) { IResource movedFile = javaBuilder . workspaceRoot . getFile ( sourceDelta . getMovedToPath ( ) ) ; JavaBuilder . removeProblemsAndTasksFor ( movedFile ) ; } } else { if ( JavaBuilder . DEBUG ) System . out . println ( ( "Found<seq2seq4repair_space>removed<seq2seq4repair_space>source<seq2seq4repair_space>file<seq2seq4repair_space>" + ( typePath . toString ( ) ) ) ) ; addDependentsOf ( typePath , true ) ; if ( ( definedTypeNames . length ) > 0 ) { IPath packagePath = typePath . removeLastSegments ( 1 ) ; for ( int i = 0 , l = definedTypeNames . length ; i < l ; i ++ ) removeClassFile ( packagePath . append ( new String ( definedTypeNames [ i ] ) ) , md . binaryFolder ) ; } } newState . removeLocator ( typeLocator ) ; return ; case IResourceDelta . CHANGED : if ( ( ( ( sourceDelta . getFlags ( ) ) & ( IResourceDelta . CONTENT ) ) == 0 ) && ( ( ( sourceDelta . getFlags ( ) ) & ( IResourceDelta . ENCODING ) ) == 0 ) ) return ;

Fix:
if ( Util . isJavaLikeFileName ( resourceName ) ) {