Bug 40409 quick fix: nonsensical proposal [quick fix]
20030716 void f(){ int i= f(); } the proposal you get is: 'change variable type to void' which makes no sense
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/text/correction/LocalCorrectionsSubProcessor.java
ASTRewrite rewrite= new ASTRewrite(methodDeclaration);
	
				String label= CorrectionMessages.getFormattedString("LocalCorrectionsSubProcessor.changereturntype.description", binding.getName()); 
				Image image= JavaPluginImages.get(JavaPluginImages.IMG_CORRECTION_CHANGE);
				LinkedCorrectionProposal proposal= new LinkedCorrectionProposal(label, cu, rewrite, 6, image);
				String returnTypeName= proposal.addImport(binding);
				
				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(), binding);
				for (int i= 0; i < typeSuggestions.length; i++) {
					proposal.addLinkedModeProposal(returnKey, typeSuggestions[i]);
				}
				
				proposal.ensureNoModifications();
				proposals.add(proposal);
			}
		}
		if (parentNodeType == ASTNode.VARIABLE_DECLARATION_FRAGMENT) {
			VariableDeclarationFragment fragment= (VariableDeclarationFragment) selectedNode.getParent();
			ASTNode parent= fragment.getParent();
			Type typeNode= null;			
			if (parent instanceof VariableDeclarationStatement) {
				VariableDeclarationStatement stmt= (VariableDeclarationStatement) parent;
				if (stmt.fragments().size() == 1) {
					typeNode= stmt.getType();
				}