Bug 67944 Regression: package explorer doesn't show folders with non package names anymore
RC3 The regression was introduced by a fix we put in into M5. The bug number is 45062. However this problem was already raised against 2.1 and we fixed it for 2.1.1 since we considered it major there. The problem appears in situations where clients create a folder insides a source folder with a non package name (for example a-b) and source folder == output folder. We havent't seen this since Eclipse developement setup is src and output folder bin. Test cases: - create normal Java project - select project - New->Folder - enter name a-b observe: folder doesn't show-up.
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/filters/OutputFolderFilter.java
IProject proj= folder.getProject();
			try {
				if (!proj.hasNature(JavaCore.NATURE_ID))
					return true;
				
				IJavaProject jProject= JavaCore.create(folder.getProject());
				if (jProject == null || !jProject.exists())
					return true;
				
				
				IPath defaultOutputLocation= jProject.getOutputLocation();
				IPath folderPath= folder.getFullPath();
				if (defaultOutputLocation != null && defaultOutputLocation.isPrefixOf(folderPath))
					return false;
				
				
				IClasspathEntry[] cpEntries= jProject.getRawClasspath();
				for (int i= 0, length= cpEntries.length; i < length; i++) {
					IPath outputLocation= cpEntries[i].getOutputLocation();
					if (outputLocation != null && outputLocation.isPrefixOf(folderPath))
						return false;
				}
			} catch (CoreException ex) {
				return true;
			}
		}
		return true;
	}
}