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/core/AddImportTest.java
public void testAddImportAction1() throws Exception {
		IPackageFragmentRoot sourceFolder= JavaProjectHelper.addSourceContainer(fJProject1, "src");
		IPackageFragment pack1= sourceFolder.createPackageFragment("pack1", false, null);
		StringBuffer buf= new StringBuffer();
		buf.append("package pack1;\n");
		buf.append("\n");
		buf.append("import java.lang.System;\n");
		buf.append("\n");		
		buf.append("public class C {\n");
		buf.append("    java.util.Vector c= null;\n");
		buf.append("}\n");
		ICompilationUnit cu= pack1.createCompilationUnit("C.java", buf.toString(), false, null);
		
		IPath path= cu.getPath();
		
		FileBuffers.getTextFileBufferManager().connect(path, null);
		try {
			IDocument doc= FileBuffers.getTextFileBufferManager().getTextFileBuffer(path).getDocument();
			int selOffset= buf.indexOf("Vector");
		
			AddImportsOperation op= new AddImportsOperation(cu, doc, selOffset, 0, null);
			op.run(null);
			buf= new StringBuffer();
			buf.append("package pack1;\n");
			buf.append("\n");
			buf.append("import java.lang.System;\n");
			buf.append("import java.util.Vector;\n");
			buf.append("\n");		
			buf.append("public class C {\n");