1
0
Fork 0
mirror of https://github.com/beefytech/Beef.git synced 2025-06-10 20:42:21 +02:00

More operator constraint compliance

This commit is contained in:
Brian Fiete 2020-08-10 14:45:11 -07:00
parent 32cd6d8841
commit 2e3356d04a
8 changed files with 27 additions and 25 deletions

View file

@ -18943,7 +18943,7 @@ void BfExprEvaluator::PerformBinaryOperation(BfAstNode* leftExpression, BfAstNod
works = true;
}
}
else if (opConstraint.mBinaryOp == oppositeBinaryOp)
else if ((oppositeBinaryOp != BfBinaryOp_None) && (opConstraint.mBinaryOp == oppositeBinaryOp))
{
if ((mModule->CanCast(args[0].mTypedValue, opConstraint.mRightType)) &&
(mModule->CanCast(args[1].mTypedValue, opConstraint.mLeftType)))