diff options
Diffstat (limited to 'org.eclipse.jdt.core/compiler/org/eclipse/jdt/internal/compiler/ast/WhileStatement.java')
-rw-r--r-- | org.eclipse.jdt.core/compiler/org/eclipse/jdt/internal/compiler/ast/WhileStatement.java | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/org.eclipse.jdt.core/compiler/org/eclipse/jdt/internal/compiler/ast/WhileStatement.java b/org.eclipse.jdt.core/compiler/org/eclipse/jdt/internal/compiler/ast/WhileStatement.java index e35ea9c0be..54b3a16fc9 100644 --- a/org.eclipse.jdt.core/compiler/org/eclipse/jdt/internal/compiler/ast/WhileStatement.java +++ b/org.eclipse.jdt.core/compiler/org/eclipse/jdt/internal/compiler/ast/WhileStatement.java @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2000, 2011 IBM Corporation and others. + * Copyright (c) 2000, 2012 IBM Corporation and others. * All rights reserved. This program and the accompanying materials * are made available under the terms of the Eclipse Public License v1.0 * which accompanies this distribution, and is available at @@ -10,6 +10,7 @@ * Stephan Herrmann - Contributions for * bug 319201 - [null] no warning when unboxing SingleNameReference causes NPE * bug 349326 - [1.7] new warning for missing try-with-resources + * bug 345305 - [compiler][null] Compiler misidentifies a case of "variable can only be null" *******************************************************************************/ package org.eclipse.jdt.internal.compiler.ast; @@ -64,7 +65,7 @@ public class WhileStatement extends Statement { currentScope, (condLoopContext = new LoopingFlowContext(flowContext, flowInfo, this, null, - null, currentScope)), + null, currentScope, true)), condInfo); if ((this.condition.implicitConversion & TypeIds.UNBOXING) != 0) { this.condition.checkNPE(currentScope, flowContext, flowInfo); @@ -100,7 +101,8 @@ public class WhileStatement extends Statement { this, this.breakLabel, this.continueLabel, - currentScope); + currentScope, + true); if (isConditionFalse) { actionInfo = FlowInfo.DEAD_END; } else { |