[color=blue]
>Is IntPtr a managed or unmanaged data type in c#?[/color]
Managed. C# only produces managed code, you can't have any unmanaged
types.
[color=blue]
>Do I need to be doing
>Intptr = IPtr;
>fixed(void * ptr = (void *)IPtr )
>{
>
>
>....
>}
>
>to avoid relocation? or can I use
>
>
>void *ptr = (void *)Iptr without fixed?[/color]
Most likely no, but it depends on what the IntPtr is pointing at. I
assume you wouldn't have an IntPtr pointing to something managed
unless you had already pinned it. The first piece of code won't work
though.
Comment