Skip to content

Commit

Permalink
Add back IsArray check.
Browse files Browse the repository at this point in the history
  • Loading branch information
AaronRobinsonMSFT committed Nov 25, 2024
1 parent e58217b commit 1cd7f1d
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions src/coreclr/System.Private.CoreLib/src/System/RuntimeHandles.cs
Original file line number Diff line number Diff line change
Expand Up @@ -976,12 +976,12 @@ internal static unsafe RuntimeType GetDeclaringType(RuntimeMethodHandleInternal
{
Debug.Assert(!method.IsNullHandle());
MethodTable* pMT = GetMethodTable(method);
// if (pMT->IsArray)
// {
// IntPtr handle = GetHandleForArray(pMT);
// return RuntimeTypeHandle.GetRuntimeTypeFromHandle(handle);
// }
// else
if (pMT->IsArray)
{
IntPtr handle = GetHandleForArray(pMT);
return RuntimeTypeHandle.GetRuntimeTypeFromHandle(handle);
}
else
{
return RuntimeTypeHandle.GetRuntimeType(pMT);
}
Expand Down

0 comments on commit 1cd7f1d

Please sign in to comment.