Re: [Mono-dev] Where can I find GetTargetHandle, etc?
On Jun 21, 2013, at 7:42 PM, Dan Barowy wrote: > [MethodImplAttribute(MethodImplOptions.InternalCall)] > private extern static int GetTargetHandle(object obj, int handle, > GCHandleType type); MethodImplOptions.InternalCall means "implemented in libmono*.so", so you need to look in mono/mono. The easiest way is usually a recursive grep, which would find: https://github.com/mono/mono/blob/master/mono/metadata/gc.c#L527 https://github.com/mono/mono/blob/master/mono/metadata/gc.c#L550 The C# method is hooked up to the above C method via https://github.com/mono/mono/blob/master/mono/metadata/icall-def.h#L667 https://github.com/mono/mono/blob/master/mono/metadata/icall.c - Jon ___ Mono-devel-list mailing list Mono-devel-list@lists.ximian.com http://lists.ximian.com/mailman/listinfo/mono-devel-list
[Mono-dev] Where can I find GetTargetHandle, etc?
Hi everyone, I see in: mono/mcs/class/corlib/System.Runtime.InteropServices/GCHandle.cs declarations for external methods, like: [MethodImplAttribute(MethodImplOptions.InternalCall)] private extern static int GetTargetHandle(object obj, int handle, GCHandleType type); [MethodImplAttribute(MethodImplOptions.InternalCall)] private extern static void FreeHandle(int handle); etc., but if I search the mono codebase (using find and grep at the mono root dir), I am unable to find these method definitions, which is a little puzzling. Does anyone know where I should look? Also, it's pretty convenient that mono has a .sln file. Does corlib also have something like this? Thanks, Dan ___ Mono-devel-list mailing list Mono-devel-list@lists.ximian.com http://lists.ximian.com/mailman/listinfo/mono-devel-list