Buggy code:
public class JavaProject extends Openable implements IProjectNature , IJavaProject , SuffixConstants { public static final String CLASSPATH_FILENAME = ".classpath" ; public static final IClasspathEntry [ ] INVALID_CLASSPATH = new IClasspathEntry [ 0 ] ; protected static final boolean IS_CASE_SENSITIVE = ! ( new File ( "Temp" ) . equals ( new File ( "temp" ) ) ) ; protected static final String [ ] NO_PREREQUISITES = new String [ 0 ] ; public static final String PREF_FILENAME = ".jprefs" ; private static final IClasspathEntry [ ] RESOLUTION_IN_PROGRESS = new IClasspathEntry [ 0 ] ; protected IProject project ; public static IPath canonicalizedPath ( IPath externalPath ) { } public static boolean hasJavaNature ( IProject project ) { } public static void updateAllCycleMarkers ( Map preferredClasspaths ) throws JavaModelException { } public JavaProject ( ) { } public JavaProject ( IProject project , JavaElement parent ) { } protected void addToBuildSpec ( String builderID ) throws CoreException { } protected boolean buildStructure ( OpenableElementInfo info , IProgressMonitor pm , Map newElements , IResource underlyingResource ) throws JavaModelException { } protected void closing ( Object info ) { } public void computeChildren ( JavaProjectElementInfo info ) throws JavaModelException { } private void computeExpandedClasspath ( ClasspathEntry referringEntry , boolean ignoreUnresolvedVariable , boolean generateMarkerOnError , HashSet rootIDs , ObjectVector accumulatedEntries , Map preferredClasspaths , Map preferredOutputs ) throws JavaModelException { } public IPackageFragmentRoot [ ] computePackageFragmentRoots ( IClasspathEntry resolvedEntry ) { } public void computePackageFragmentRoots ( IClasspathEntry resolvedEntry , ObjectVector accumulatedRoots , HashSet rootIDs , IClasspathEntry referringEntry , boolean checkExistency , boolean retrieveExportedRoots , Map rootToResolvedEntries ) throws JavaModelException { String rootID = ( ( ClasspathEntry ) ( resolvedEntry ) ) . rootID ( ) ; if ( rootIDs . contains ( rootID ) ) return ; IPath projectPath = this . project . getFullPath ( ) ; IPath entryPath = resolvedEntry . getPath ( ) ; IWorkspaceRoot workspaceRoot = ResourcesPlugin . getWorkspace ( ) . getRoot ( ) ; IPackageFragmentRoot root = null ; switch ( resolvedEntry . getEntryKind ( ) ) { case IClasspathEntry . CPE_SOURCE : if ( projectPath . isPrefixOf ( entryPath ) ) { if ( checkExistency ) { Object target = JavaModel . getTarget ( workspaceRoot , entryPath , checkExistency ) ; if ( target == null ) return ; if ( ( target instanceof IFolder ) || ( target instanceof IProject ) ) { root = getPackageFragmentRoot ( ( ( IResource ) ( target ) ) ) ; } } else { root = getFolderPackageFragmentRoot ( entryPath ) ; } } break ; case IClasspathEntry . CPE_LIBRARY : if ( ( referringEntry != null ) && ( ! ( resolvedEntry . isExported ( ) ) ) ) return ; if ( checkExistency ) { Object target = JavaModel . getTarget ( workspaceRoot , entryPath , checkExistency ) ; if ( target == null ) return ; if ( target instanceof IResource ) { root = getPackageFragmentRoot ( ( ( IResource ) ( target ) ) ) ; } else { <START_BUG> if ( ( ( ( File ) ( target ) ) . isFile ( ) ) && ( org . eclipse . jdt . internal . compiler . util . Util . isArchiveFileName ( entryPath . lastSegment ( ) ) ) ) { <END_BUG> root = new JarPackageFragmentRoot ( entryPath , this ) ; } } } else { root = getPackageFragmentRoot ( entryPath ) ; } break ; case IClasspathEntry . CPE_PROJECT : if ( ! retrieveExportedRoots ) return ; if ( ( referringEntry != null ) && ( ! ( resolvedEntry . isExported ( ) ) ) ) return ; IResource member = workspaceRoot . findMember ( entryPath ) ; if ( ( member != null ) && ( ( member . getType ( ) ) == ( IResource . PROJECT ) ) ) { IProject requiredProjectRsc = ( ( IProject ) ( member ) ) ; if ( JavaProject . hasJavaNature ( requiredProjectRsc ) ) { rootIDs . add ( rootID ) ; JavaProject requiredProject = ( ( JavaProject ) ( JavaCore . create ( requiredProjectRsc ) ) ) ; requiredProject . computePackageFragmentRoots ( requiredProject . getResolvedClasspath ( true , false , false ) , accumulatedRoots , rootIDs , ( rootToResolvedEntries == null ? resolvedEntry : ( ( ClasspathEntry ) ( resolvedEntry ) ) . combineWith ( ( ( ClasspathEntry ) ( referringEntry ) ) ) ) , checkExistency , retrieveExportedRoots , rootToResolvedEntries ) ; } break ; } } if ( root != null ) { accumulatedRoots . add ( root ) ; rootIDs . add ( rootID ) ; if ( rootToResolvedEntries != null ) rootToResolvedEntries . put ( root , ( ( ClasspathEntry ) ( resolvedEntry ) ) . combineWith ( ( ( ClasspathEntry ) ( referringEntry ) ) ) ) ; } } public IPackageFragmentRoot [ ] computePackageFragmentRoots ( IClasspathEntry [ ] resolvedClasspath , boolean retrieveExportedRoots , Map rootToResolvedEntries ) throws JavaModelException { } public void computePackageFragmentRoots ( IClasspathEntry [ ] resolvedClasspath , ObjectVector accumulatedRoots , HashSet rootIDs , IClasspathEntry referringEntry , boolean checkExistency , boolean retrieveExportedRoots , Map rootToResolvedEntries ) throws JavaModelException { } public String computeSharedPropertyFileName ( QualifiedName qName ) { } public void configure ( ) throws CoreException { } public boolean contains ( IResource resource ) { } void createClasspathProblemMarker ( IJavaModelStatus status ) { } protected Object createElementInfo ( ) { } protected IClasspathEntry [ ] decodeClasspath ( String xmlClasspath , boolean createMarker , boolean logProblems ) { } public void deconfigure ( ) throws CoreException { } protected IClasspathEntry [ ] defaultClasspath ( ) { } protected IPath defaultOutputLocation ( ) { } protected String encodeClasspath ( IClasspathEntry [ ] classpath , IPath outputLocation , boolean indent ) throws JavaModelException { } public boolean equals ( Object o ) { } public boolean exists ( ) { } public IJavaElement findElement ( IPath path ) throws JavaModelException { } public IJavaElement findElement ( IPath path , WorkingCopyOwner owner ) throws JavaModelException { }

Fix:
if ( ( JavaModel . isFile ( target ) ) && ( org . eclipse . jdt . internal . compiler . util . Util . isArchiveFileName ( entryPath . lastSegment ( ) ) ) ) {