About This eBook by Bart De Smet

Safari, the world’s most comprehensive technology and business learning platform.

Find the exact information you need to solve a problem on the fly, or go deeper to master the technologies and skills you need to succeed

Start Free Trial

No credit card required

O'Reilly logo

Native Interop with IntPtr

The notion of references in managed code is morally equivalent to pointers, as known from native code programming. There are a whole series of differences, though, which have to do with type safety, the presence of a garbage collector, and the desire to build a platform-independent runtime. The implications brought to us by type safety and the use of a GC are closely related, as can be seen from the way the collector traces objects by following references, requiring access to type information. But there’s more, the fact objects can move in memory means that the object address captured in a reference can and will change during the program’s lifetime.

Our previous discussion should be enough to understand already that ...

Find the exact information you need to solve a problem on the fly, or go deeper to master the technologies and skills you need to succeed

Start Free Trial

No credit card required