added NaN operand of constructor


git-svn-id: https://svn.code.sf.net/p/jode/code/trunk@833 379699f6-c40d-0410-875b-85095c16579e
stable
jochen 26 years ago
parent cf499934d0
commit 003032328f
  1. 6
      jode/jode/expr/CompareUnaryOperator.java

@ -65,15 +65,15 @@ public class CompareUnaryOperator extends Operator {
boolean negated = false; boolean negated = false;
int opIndex = getOperatorIndex(); int opIndex = getOperatorIndex();
if (cmpOp.allowsNAN && getOperatorIndex() > NOTEQUALS_OP) { if (cmpOp.allowsNaN && getOperatorIndex() > NOTEQUALS_OP) {
if (cmpOp.greaterOnNAN == if (cmpOp.greaterOnNaN ==
(opIndex == GREATEREQ_OP || opIndex == GREATER_OP)) { (opIndex == GREATEREQ_OP || opIndex == GREATER_OP)) {
negated = true; negated = true;
opIndex ^= 1; opIndex ^= 1;
} }
} }
Expression newOp = new CompareBinaryOperator Expression newOp = new CompareBinaryOperator
(cmpOp.compareType, opIndex) (cmpOp.compareType, opIndex, cmpOp.allowsNaN)
.addOperand(cmpOp.subExpressions[1]) .addOperand(cmpOp.subExpressions[1])
.addOperand(cmpOp.subExpressions[0]); .addOperand(cmpOp.subExpressions[0]);

Loading…
Cancel
Save