C
C#7mo ago
joki

How would one go about finding the size of a delegate* <void>, be the function managed or unmanaged?

I need to get the length of the data inside the managed/unmanaged function pointer delegate* <T> (void in this case), how would I go about doing that as Marshal or Unsafe dont work.
1 Reply
joki
joki7mo ago
I tried google but it just pops pages about regular delegates in c#, no mention about getting their size Could there be a sequence of bytes at the end of the function data signifying its end? No I do not want the size of the pointer That irrelevant I need the size of the structure the pointer holds (aka the size of the method stored in that memory space) Doesn't matter, I can use C and interop call it with C#