Skip to content
This repository was archived by the owner on Jan 23, 2023. It is now read-only.
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
25 changes: 22 additions & 3 deletions src/vm/jitinterface.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -8860,13 +8860,32 @@ CORINFO_METHOD_HANDLE CEEInfo::resolveVirtualMethodHelper(CORINFO_METHOD_HANDLE
pOwnerMT = pOwnerMT->GetCanonicalMethodTable();
}

pDevirtMD = pDerivedMT->GetMethodDescForInterfaceMethod(TypeHandle(pOwnerMT), pBaseMD);
// In a try block because the interface method resolution might end up being
// ambiguous (diamond inheritance case of default interface methods).
EX_TRY
{
pDevirtMD = pDerivedMT->GetMethodDescForInterfaceMethod(TypeHandle(pOwnerMT), pBaseMD);
}
EX_CATCH
{
}
EX_END_CATCH(RethrowTransientExceptions)
}
else if (!pBaseMD->HasClassOrMethodInstantiation())
{
pDevirtMD = pDerivedMT->GetMethodDescForInterfaceMethod(pBaseMD);
// In a try block because the interface method resolution might end up being
// ambiguous (diamond inheritance case of default interface methods).
EX_TRY
{
pDevirtMD = pDerivedMT->GetMethodDescForInterfaceMethod(pBaseMD);
}
EX_CATCH
{
}
EX_END_CATCH(RethrowTransientExceptions)
}
else

if (pDevirtMD == nullptr)
{
return nullptr;
}
Expand Down