On Thu, Mar 20, 2014 at 6:46 PM, [email protected] < [email protected]> wrote:
> > On 20 Mar 2014, at 22:43, Jonathan Lima <[email protected]> wrote: > > > AFAIK MonoObject is the pointer to the object in the heap, so you just > have to compare the pointers. > > > > Jonathan > > > I think that if the MonoObject instance isn't pinned then there is no > guarantee that successive unmanaged pointers to a managed object will have > the same value. > MonoObject pointers are what we call a raw/naked pointer. They must be transient and never escape the C stack. You can compare them by value. If you need a persistent pointer, use gchandled and to compare them, fetch their values and compare those.
_______________________________________________ Mono-list maillist - [email protected] http://lists.ximian.com/mailman/listinfo/mono-list
