Buggy code:
public class AND_AND_Expression extends BinaryExpression { int rightInitStateIndex = - 1 ; int mergedInitStateIndex = - 1 ; public AND_AND_Expression ( Expression left , Expression right , int operator ) { } public FlowInfo analyseCode ( BlockScope currentScope , FlowContext flowContext , FlowInfo flowInfo ) { } public void generateCode ( BlockScope currentScope , CodeStream codeStream , boolean valueRequired ) { int pc = codeStream . position ; if ( ( constant ) != ( Constant . NotAConstant ) ) { if ( valueRequired ) codeStream . generateConstant ( constant , implicitConversion ) ; codeStream . recordPositionsFrom ( pc , this . sourceStart ) ; return ; } Constant cst = right . constant ; if ( cst != ( NotAConstant ) ) { if ( ( cst . booleanValue ( ) ) == true ) { this . left . generateCode ( currentScope , codeStream , valueRequired ) ; } else { this . left . generateCode ( currentScope , codeStream , false ) ; if ( valueRequired ) <START_BUG> codeStream . iconst_1 ( ) ; <END_BUG> } if ( ( mergedInitStateIndex ) != ( - 1 ) ) { codeStream . removeNotDefinitelyAssignedVariables ( currentScope , mergedInitStateIndex ) ; } codeStream . generateImplicitConversion ( implicitConversion ) ; codeStream . updateLastRecordedEndPC ( codeStream . position ) ; codeStream . recordPositionsFrom ( pc , this . sourceStart ) ; return ; } Label falseLabel = new Label ( codeStream ) ; Label endLabel ; cst = left . optimizedBooleanConstant ( ) ; boolean leftIsConst = cst != ( NotAConstant ) ; boolean leftIsTrue = leftIsConst && ( ( cst . booleanValue ( ) ) == true ) ; cst = right . optimizedBooleanConstant ( ) ; boolean rightIsConst = cst != ( NotAConstant ) ; boolean rightIsTrue = rightIsConst && ( ( cst . booleanValue ( ) ) == true ) ; generateOperands : { if ( leftIsConst ) { left . generateCode ( currentScope , codeStream , false ) ; if ( ! leftIsTrue ) { break generateOperands ; } } else { left . generateOptimizedBoolean ( currentScope , codeStream , null , falseLabel , true ) ; } if ( ( rightInitStateIndex ) != ( - 1 ) ) { codeStream . addDefinitelyAssignedVariables ( currentScope , rightInitStateIndex ) ; } if ( rightIsConst ) { right . generateCode ( currentScope , codeStream , false ) ; } else { right . generateOptimizedBoolean ( currentScope , codeStream , null , falseLabel , valueRequired ) ; } } if ( ( mergedInitStateIndex ) != ( - 1 ) ) { codeStream . removeNotDefinitelyAssignedVariables ( currentScope , mergedInitStateIndex ) ; } if ( valueRequired ) { if ( leftIsConst && ( ! leftIsTrue ) ) { codeStream . iconst_0 ( ) ; codeStream . updateLastRecordedEndPC ( codeStream . position ) ; } else { if ( rightIsConst && ( ! rightIsTrue ) ) { codeStream . iconst_0 ( ) ; codeStream . updateLastRecordedEndPC ( codeStream . position ) ; } else { codeStream . iconst_1 ( ) ; } if ( falseLabel . hasForwardReferences ( ) ) { if ( ( ( bits ) & ( ValueForReturnMASK ) ) != 0 ) { codeStream . ireturn ( ) ; falseLabel . place ( ) ; codeStream . iconst_0 ( ) ; } else { codeStream . goto_ ( ( endLabel = new Label ( codeStream ) ) ) ; codeStream . decrStackSize ( 1 ) ; falseLabel . place ( ) ; codeStream . iconst_0 ( ) ; endLabel . place ( ) ; } } else { falseLabel . place ( ) ; } } codeStream . generateImplicitConversion ( implicitConversion ) ; codeStream . updateLastRecordedEndPC ( codeStream . position ) ; } else { falseLabel . place ( ) ; } } public void generateOptimizedBoolean ( BlockScope currentScope , CodeStream codeStream , Label trueLabel , Label falseLabel , boolean valueRequired ) { } public boolean isCompactableOperation ( ) { } public void traverse ( ASTVisitor visitor , BlockScope scope ) { } }

Fix:
codeStream . iconst_0 ( ) ;