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

Fixed fail crash

This commit is contained in:
Brian Fiete 2020-08-10 15:36:05 -07:00
parent 0783fd3318
commit d35ef0e1e8

View file

@ -18006,7 +18006,11 @@ void BfExprEvaluator::PerformUnaryOperation_OnResult(BfExpression* unaryOpExpr,
if (numericFail)
{
if (mResult.mType->IsInterface())
if (opToken == NULL)
{
BF_ASSERT(mModule->mBfIRBuilder->mIgnoreWrites);
}
else if (mResult.mType->IsInterface())
{
mModule->Fail(
StrFormat("Operator '%s' cannot be used on interface '%s'. Consider rewriting using generics and use this interface as a generic constraint.",