This repository was archived by the owner on Jan 23, 2023. It is now read-only.
File tree Expand file tree Collapse file tree 1 file changed +6
-2
lines changed Expand file tree Collapse file tree 1 file changed +6
-2
lines changed Original file line number Diff line number Diff line change @@ -780,15 +780,19 @@ Stub * CreateInstantiatingILStub(MethodDesc* pTargetMD, void* pHiddenArg)
780
780
CONTRACT_END;
781
781
782
782
SigTypeContext typeContext;
783
+ MethodTable* pStubMT;
783
784
if (pTargetMD->HasMethodInstantiation ())
784
785
{
785
786
// The pHiddenArg shall be a MethodDesc*
786
- SigTypeContext::InitTypeContext (static_cast <MethodDesc *>(pHiddenArg), &typeContext);
787
+ MethodDesc* pMD = static_cast <MethodDesc *>(pHiddenArg);
788
+ SigTypeContext::InitTypeContext (pMD, &typeContext);
789
+ pStubMT = pMD->GetMethodTable ();
787
790
}
788
791
else
789
792
{
790
793
// The pHiddenArg shall be a MethodTable*
791
794
SigTypeContext::InitTypeContext (TypeHandle::FromPtr (pHiddenArg), &typeContext);
795
+ pStubMT = static_cast <MethodTable *>(pHiddenArg);
792
796
}
793
797
794
798
MetaSig msig (pTargetMD);
@@ -837,7 +841,7 @@ Stub * CreateInstantiatingILStub(MethodDesc* pTargetMD, void* pHiddenArg)
837
841
pTargetMD->GetSig (&pSig,&cbSig);
838
842
PTR_Module pLoaderModule = pTargetMD->GetLoaderModule ();
839
843
MethodDesc * pStubMD = ILStubCache::CreateAndLinkNewILStubMethodDesc (pTargetMD->GetLoaderAllocator (),
840
- pLoaderModule-> GetILStubCache ()-> GetOrCreateStubMethodTable (pLoaderModule) ,
844
+ pStubMT ,
841
845
ILSTUB_INSTANTIATINGSTUB,
842
846
pTargetMD->GetModule (),
843
847
pSig, cbSig,
You can’t perform that action at this time.
0 commit comments