mirror of
https://github.com/beefytech/Beef.git
synced 2025-06-10 12:32:20 +02:00
Interop fixes and tests, fixing xplat struct passing issues
This commit is contained in:
parent
4cf6af53bd
commit
5da74382d4
31 changed files with 1569 additions and 239 deletions
|
@ -4885,12 +4885,12 @@ void BfModule::Visit(BfReturnStatement* returnStmt)
|
|||
BfType* origType;
|
||||
BfExprEvaluator exprEvaluator(this);
|
||||
bool alreadyWritten = false;
|
||||
if (mCurMethodInstance->HasStructRet())
|
||||
if (mCurMethodInstance->GetStructRetIdx() != -1)
|
||||
exprEvaluator.mReceivingValue = &mCurMethodState->mRetVal;
|
||||
if (mCurMethodInstance->mMethodDef->mIsReadOnly)
|
||||
exprEvaluator.mAllowReadOnlyReference = true;
|
||||
auto retValue = CreateValueFromExpression(exprEvaluator, returnStmt->mExpression, expectingReturnType, BfEvalExprFlags_AllowRefExpr, &origType);
|
||||
if (mCurMethodInstance->HasStructRet())
|
||||
if (mCurMethodInstance->GetStructRetIdx() != -1)
|
||||
alreadyWritten = exprEvaluator.mReceivingValue == NULL;
|
||||
MarkScopeLeft(&mCurMethodState->mHeadScope);
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue