Bug 75193 Add a quick-fix for "'enum' should not be used as an identifier [...]"
Version 3.1.M2. Add a quick-fix for: 'enum' should not be used as an identifier, since it is a reserved keyword from source level 1.5 The quick-fix would do a rename on local variable called 'enum' to 'enumeration'.
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/text/correction/LocalCorrectionsSubProcessor.java
public static void addUnqualifiedFieldAccessProposal(IInvocationContext context, IProblemLocation problem, Collection proposals) throws CoreException {
		ASTNode selectedNode= problem.getCoveringNode(context.getASTRoot());
		while (selectedNode instanceof QualifiedName) {
			selectedNode= ((QualifiedName) selectedNode).getQualifier();
		}
		if (!(selectedNode instanceof SimpleName)) {
			return;
		}
		SimpleName name = (SimpleName) selectedNode;
		IBinding binding= name.resolveBinding();
		if (binding.getKind() != IBinding.VARIABLE) {
			return;
		}
		
		ASTRewrite rewrite= ASTRewrite.create(name.getAST());
		ImportRewrite imports= new ImportRewrite(context.getCompilationUnit());
		
		ITypeBinding declaringClass= ((IVariableBinding) binding).getDeclaringClass();
		String qualifier;
		if (Modifier.isStatic(binding.getModifiers())) {
			qualifier= imports.addImport(declaringClass);
		} else {
			ITypeBinding currType= Bindings.getBindingOfParentType(name);
			if (Bindings.isSuperType(declaringClass, currType)) {
				qualifier= "this"; 
			} else {
				String outer= imports.addImport(declaringClass);
				qualifier= outer + ".this"; 
			}
		}