Bug 74928 NPE in AdvancedQuickAssistProcessor$3.isCovered
eclipse.buildId=I200409231635 java.fullversion=J2RE 1.4.2 IBM J9 2.2 Windows XP x86-32 j9n142-20040915 (JIT enabled) J9VM - 20040914_1123_lHdSMR JIT - r7_level20040912_1800 BootLoader constants: OS=win32, ARCH=x86, WS=win32, NL=de_CH Command-line arguments: -update -keyring c:\eclipse\.keyring -application org.eclipse.ui.ide.workbench -showlocation Sorry no steps. Found in .log. Nothing special in UI !ENTRY org.eclipse.jdt.ui 4 10001 Sep 24, 2004 08:54:10.548 !MESSAGE Internal Error !STACK 0 java.lang.NullPointerException at org.eclipse.jdt.internal.ui.text.correction.AdvancedQuickAssistProcessor$3.isCovered(AdvancedQuickAssistProcessor.java:679) at org.eclipse.jdt.internal.ui.text.correction.AdvancedQuickAssistProcessor$3.postVisit(AdvancedQuickAssistProcessor.java:673) at org.eclipse.jdt.core.dom.ASTNode.accept(ASTNode.java:2452) at org.eclipse.jdt.internal.ui.text.correction.AdvancedQuickAssistProcessor.getFullyCoveredNodes(AdvancedQuickAssistProcessor.java:670) at org.eclipse.jdt.internal.ui.text.correction.AdvancedQuickAssistProcessor.getInverseConditionProposals(AdvancedQuickAssistProcessor.java:344) at org.eclipse.jdt.internal.ui.text.correction.AdvancedQuickAssistProcessor.hasAssists(AdvancedQuickAssistProcessor.java:51) at org.eclipse.jdt.internal.ui.text.correction.JavaCorrectionProcessor.hasAssists(JavaCorrectionProcessor.java:143) at org.eclipse.jdt.internal.ui.text.correction.QuickAssistLightBulbUpdater.calculateLightBulb(QuickAssistLightBulbUpdater.java:229) at org.eclipse.jdt.internal.ui.text.correction.QuickAssistLightBulbUpdater.doSelectionChanged(QuickAssistLightBulbUpdater.java:222) at org.eclipse.jdt.internal.ui.text.correction.QuickAssistLightBulbUpdater.access$0(QuickAssistLightBulbUpdater.java:205) at org.eclipse.jdt.internal.ui.text.correction.QuickAssistLightBulbUpdater$1.selectionChanged(QuickAssistLightBulbUpdater.java:129) at org.eclipse.jdt.internal.ui.viewsupport.SelectionListenerWithASTManager$PartListenerGroup.calculateASTandInform(SelectionListenerWithASTManager.java:172) at org.eclipse.jdt.internal.ui.viewsupport.SelectionListenerWithASTManager$3.run(SelectionListenerWithASTManager.java:141) at org.eclipse.core.internal.jobs.Worker.run(Worker.java:66)
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/text/correction/AdvancedQuickAssistProcessor.java
}
		}
		return result;
	}
	private static Expression getParenthesizedForAndIfNeeded(AST ast, ASTRewrite rewrite, Expression expression) {
		boolean addParentheses = false;
		int nodeType = expression.getNodeType();
		if (nodeType == ASTNode.INFIX_EXPRESSION) {
			InfixExpression infixExpression = (InfixExpression) expression;
			addParentheses = infixExpression.getOperator() == InfixExpression.Operator.CONDITIONAL_OR;
		} else {
			addParentheses = nodeType == ASTNode.CONDITIONAL_EXPRESSION || nodeType == ASTNode.ASSIGNMENT
					|| nodeType == ASTNode.INSTANCEOF_EXPRESSION;
		}
		expression = (Expression) rewrite.createCopyTarget(expression);
		if (addParentheses) {
			return getParenthesizedExpression(ast, expression);
		}
		return expression;
	}
	private static Expression getParenthesizedExpression(AST ast, Expression expression) {
		ParenthesizedExpression parenthesizedExpression = ast.newParenthesizedExpression();
		parenthesizedExpression.setExpression(expression);
		return parenthesizedExpression;
	}
	private boolean getSplitAndConditionProposals(IInvocationContext context, ASTNode node,
			Collection resultingCollections) {
		Operator andOperator = InfixExpression.Operator.CONDITIONAL_AND;
		
		if (!(node instanceof InfixExpression)) {