Bug 32022 Indirect static proposal: Wrong compiler positions
QuickFix produce wrong code while trying to fix the way class accesses field of the static member of the static class instance, i.e.: instance.staticField.flag = true; Where "instance" is the static field of the same class as caller, "staticField" its static member (instance of inner class StaticField) and the "flag" is a public field. Code is a bit meaningless, but there is no matter. Using QuickFix results in: StaticField.flag = true; while should be: InstanceClass.staticField.flag = true; or staticField.flag = true;
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/text/correction/LocalCorrectionsSubProcessor.java
if (parentNodeType == ASTNode.RETURN_STATEMENT) {
			BodyDeclaration decl= ASTResolving.findParentBodyDeclaration(selectedNode);
			if (decl instanceof MethodDeclaration) {
				MethodDeclaration methodDeclaration= (MethodDeclaration) decl;
	
				currBinding= Bindings.normalizeTypeBinding(currBinding);
				if (currBinding == null) {
					currBinding= astRoot.getAST().resolveWellKnownType("java.lang.Object"); 
				}
	
				ASTRewrite rewrite= new ASTRewrite(methodDeclaration);
	
				String label= CorrectionMessages.getFormattedString("LocalCorrectionsSubProcessor.changereturntype.description", currBinding.getName()); 
				Image image= JavaPluginImages.get(JavaPluginImages.IMG_CORRECTION_CHANGE);
				LinkedCorrectionProposal proposal= new LinkedCorrectionProposal(label, cu, rewrite, 6, image);
				String returnTypeName= proposal.addImport(currBinding);
				
				Type newReturnType= ASTNodeFactory.newType(astRoot.getAST(), returnTypeName);
				rewrite.markAsReplaced(methodDeclaration.getReturnType(), newReturnType);
				
				String returnKey= "return"; 
				proposal.markAsLinked(rewrite, newReturnType, true, returnKey);
				ITypeBinding[] typeSuggestions= ASTResolving.getRelaxingTypes(astRoot.getAST(), currBinding);
				for (int i= 0; i < typeSuggestions.length; i++) {
					proposal.addLinkedModeProposal(returnKey, typeSuggestions[i]);
				}
				
				proposal.ensureNoModifications();