boolean (@NotNull DfaValue value1, @NotNull DfaValue value2) { if (value1 instanceof DfaBinOpValue binOp1 && value2 instanceof DfaBinOpValue binOp2) { return binOp1.getOperation() == binOp2.getOperation() && areEqual(binOp1.getLeft(), binOp2.getLeft()) && areEqual(binOp1.getRight(), binOp2.getRight()); } DfType dfType1 = getDfType(value1); DfType dfType2 = getDfType(value2); if (dfType1 instanceof DfConstantType && dfType2 instanceof DfConstantType && dfType1.equals(dfType2)) return true; if (!(value1 instanceof DfaVariableValue)) return false; if (!(value2 instanceof DfaVariableValue)) return false; if (value1 == value2) return true; int index1 = getEqClassIndex(value1); int index2 = getEqClassIndex(value2); return index1 != -1 && index1 == index2; }