boolean (@NotNull DfaRelation dfaRelation) { DfaValue dfaLeft = dfaRelation.leftOperand(); DfaValue dfaRight = dfaRelation.rightOperand(); RelationType relationType = dfaRelation.relationType(); if (DfaTypeValue.isUnknown(dfaLeft) || DfaTypeValue.isUnknown(dfaRight)) return true; // Such relations are only useful to update ephemeral marks in applyContractCondition if (dfaLeft instanceof DfaTypeValue && dfaRight instanceof DfaTypeValue) return true; if (relationType == RelationType.EQ && dfaLeft instanceof DfaVariableValue && dfaRight instanceof DfaVariableValue) { checkEphemeral(dfaLeft, dfaRight); checkEphemeral(dfaRight, dfaLeft); } DfType leftType = getDfType(dfaLeft); DfType rightType = getDfType(dfaRight); if (leftType == DfType.FAIL || rightType == DfType.FAIL) { return (leftType == rightType) == (relationType == RelationType.EQ); } if (!meetDfType(dfaLeft, leftType.meetRelation(relationType, rightType))) { return false; } if (relationType.getFlipped() != null && !meetDfType(dfaRight, rightType.meetRelation(relationType.getFlipped(), leftType))) { return false; } if (!applyBinOpRelations(dfaLeft, relationType, dfaRight)) return false; return applyEquivalenceRelation(relationType, dfaLeft, dfaRight); }