mirror of
https://github.com/beefytech/Beef.git
synced 2025-06-10 12:32:20 +02:00
Added target triple support for more useful cross compilation
This commit is contained in:
parent
22ec4a86b8
commit
3bf4c792d8
15 changed files with 145 additions and 124 deletions
|
@ -241,6 +241,8 @@ bool BfMethodMatcher::InferGenericArgument(BfMethodInstance* methodInstance, BfT
|
|||
{
|
||||
if (argType == NULL)
|
||||
return false;
|
||||
if (argType->IsVar())
|
||||
return false;
|
||||
|
||||
if (wantType->IsGenericParam())
|
||||
{
|
||||
|
@ -248,7 +250,7 @@ bool BfMethodMatcher::InferGenericArgument(BfMethodInstance* methodInstance, BfT
|
|||
|
||||
BfType* methodGenericTypeConstraint = NULL;
|
||||
auto _SetGeneric = [&]()
|
||||
{
|
||||
{
|
||||
if (mCheckMethodGenericArguments[wantGenericParam->mGenericParamIdx] != argType)
|
||||
{
|
||||
if (methodGenericTypeConstraint != NULL)
|
||||
|
@ -1347,6 +1349,9 @@ bool BfMethodMatcher::CheckMethod(BfTypeInstance* typeInstance, BfMethodDef* che
|
|||
genericArg = mModule->GetPrimitiveStructType(primType->mTypeDef->mTypeCode);
|
||||
}
|
||||
|
||||
if (genericArg == NULL)
|
||||
goto NoMatch;
|
||||
|
||||
//SetAndRestoreValue<bool> ignoreError(mModule->mIgnoreErrors, true);
|
||||
if (!mModule->CheckGenericConstraints(BfGenericParamSource(methodInstance), genericArg, NULL, genericParams[checkGenericIdx], genericArgumentsSubstitute, NULL))
|
||||
{
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue