[Mono-dev] PInvoke : argument passing by ref

2005-10-22 Thread Shankari
Hello, I am trying to isolate the updates by unmanaged code if the arguments are passed by reference in Pinvoke. I looked up marshal.c and at mono_marshal_emit_native_wrapper , the by-ref argumments are being marshalled back to managed memory. I am trying to do this by the foll : After the C

Re: [Mono-dev] PInvoke : argument passing by ref

2005-10-22 Thread Zoltan Varga
Hi, The way mono marshalls data from/to native code is described here: http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dnnetcomp/html/netcfmarshallingtypes.asp If things don't work that way in mono, than it is a bug and we will fix it.

Re: [Mono-dev] PInvoke : argument passing by ref

2005-10-22 Thread Shankari
I want to know : After unmanaged code manipulates the ref object...it copies it BACK to managed memory. Where does this happen. Is it in marshal.c:mono_marshal_emit_native_wrapper ??? lines 6022 ?? /* convert the result */ if (!sig-ret-byref) { MonoMarshalSpec *spec =