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

Fixed ccompat mangling un-uniquing generic type names

This commit is contained in:
Brian Fiete 2020-09-16 04:38:19 -07:00
parent 0b20ef867b
commit 0631bb2ca8

View file

@ -1794,6 +1794,7 @@ void BfMSMangler::Mangle(StringImpl& name, bool is64Bit, BfMethodInstance* metho
else if (constant->mInt32 == 2) // CPP
{
mangleContext.mCPPMangle = true;
mangleContext.mCCompat = true;
}
}
}
@ -2046,7 +2047,12 @@ void BfMSMangler::Mangle(StringImpl& name, bool is64Bit, BfMethodInstance* metho
if (methodInst->GetExplicitInterface() != NULL)
Mangle(mangleContext, name, methodInst->GetExplicitInterface(), true);
Mangle(mangleContext, name, methodInst->GetOwner(), true);
///
{
// Only use CCompat for params, not for the owning type name - unless we're doing an explicit CPP mangle
SetAndRestoreValue<bool> prevCCompat(mangleContext.mCCompat, (mangleContext.mCCompat && mangleContext.mCPPMangle) ? true : false);
Mangle(mangleContext, name, methodInst->GetOwner(), true);
}
/*bool isCppDecl = false;
if (!isCppDecl)