Bug 76530 [options] Warn about unused local variables and private members
I think we should warn about unused local variables and unused private members by default. These things are errors akin to unused imports, which we already warn about.
org.eclipse.jdt.ui.tests/ui/org/eclipse/jdt/ui/tests/dialogs/NewProjectTestSetup.java
if (fWorkspaceProjectWithSrc != null && fWorkspaceProjectWithSrc.exists())
            JavaProjectHelper.delete(fWorkspaceProjectWithSrc);
        if (fExternalProject != null && fExternalProject.exists())
            JavaProjectHelper.delete(fExternalProject);
        JavaProjectHelper.setAutoBuilding(fAutobuilding);
    }
    
    private void createWithSrcAndBinFolder(IJavaProject project) {
        IPath srcPath= new Path("src");
        try {
            if (srcPath.segmentCount() > 0) {
                IFolder folder= project.getProject().getFolder(srcPath);
                CoreUtility.createFolder(folder, true, true, null);
            }
            
            final IPath projectPath= project.getProject().getFullPath();
    
            
            List cpEntries= new ArrayList();
            cpEntries.add(JavaCore.newSourceEntry(projectPath.append(srcPath)));
            cpEntries.addAll(Arrays.asList(PreferenceConstants.getDefaultJRELibrary()));
            IClasspathEntry[] entries= (IClasspathEntry[]) cpEntries.toArray(new IClasspathEntry[cpEntries.size()]);
            
            project.setRawClasspath(entries, null);
        } catch (CoreException e) {
            JavaPlugin.log(e);
        }
    }
}