Skip to content

Commit

Permalink
Fix function pointer as fields inspection (#83981)
Browse files Browse the repository at this point in the history
This was missed when C# function pointers support
was added to the runtime. The current fix is reporting
all functions pointers as `IntPtr` type. It should be
possible in a future update to properly represent a
more accurate type for the function pointer.
  • Loading branch information
AaronRobinsonMSFT authored Mar 27, 2023
1 parent 5bd2ed3 commit ed3721b
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/coreclr/vm/siginfo.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1648,8 +1648,8 @@ TypeHandle SigPointer::GetTypeHandleThrowing(
// Find an existing function pointer or make a new one
thRet = ClassLoader::LoadFnptrTypeThrowing((BYTE) uCallConv, cArgs, retAndArgTypes, fLoadTypes, level);
#else
DacNotImpl();
thRet = TypeHandle();
// Function pointers are interpreted as IntPtr to the debugger.
thRet = TypeHandle(CoreLibBinder::GetElementType(ELEMENT_TYPE_I));
#endif
break;
}
Expand Down

0 comments on commit ed3721b

Please sign in to comment.