* Fix FieldDesc::GetExactFieldType when FieldDesc doesn't exactly represent the owner type
To get the exact type from FieldDesc, field signature should point past the calling convention.
GetSig(&pSig, &cSig);
SigPointer sig(pSig, cSig);
+ ULONG callConv;
+ IfFailThrow(sig.GetCallingConv(&callConv));
+ _ASSERTE(callConv == IMAGE_CEE_CS_CALLCONV_FIELD);
+
// Get the generics information
SigTypeContext sigTypeContext(GetExactClassInstantiation(owner), Instantiation());
- TypeHandle thApproxFieldType = GetApproxFieldTypeHandleThrowing();
// Load the exact type
- RETURN (sig.GetTypeHandleThrowing(thApproxFieldType.GetModule(), &sigTypeContext));
+ RETURN (sig.GetTypeHandleThrowing(GetModule(), &sigTypeContext));
}
}