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

Fixed sign extension for constexpr geps

This commit is contained in:
Brian Fiete 2023-07-25 07:43:22 -07:00
parent e2f45167f9
commit 974e8ac354
2 changed files with 49 additions and 17 deletions

View file

@ -8502,6 +8502,7 @@ BfTypedValue BfExprEvaluator::CreateCall(BfAstNode* targetSrc, const BfTypedValu
argIdx++;
}
prevIgnoreWrites.Restore();
return mModule->GetDefaultTypedValue(returnType, false, BfDefaultValueKind_Addr);
}
@ -8565,6 +8566,7 @@ BfTypedValue BfExprEvaluator::CreateCall(BfAstNode* targetSrc, const BfTypedValu
mFunctionBindResult->mIRArgs.push_back(arg);
}
prevIgnoreWrites.Restore();
return mModule->GetDefaultTypedValue(returnType);
}
}
@ -8599,6 +8601,7 @@ BfTypedValue BfExprEvaluator::CreateCall(BfAstNode* targetSrc, const BfTypedValu
auto func = moduleMethodInstance.mFunc;
BfTypedValue callResult = CreateCall(targetSrc, methodInstance, func, bypassVirtual, irArgs, NULL, physCallFlags, origTarget.mType);
prevIgnoreWrites.Restore();
if ((methodInstance->mMethodDef->mIsNoReturn) && ((mBfEvalExprFlags & BfEvalExprFlags_IsExpressionBody) != 0) &&
(mExpectingType != NULL) && (callResult.mType != mExpectingType))
{