array of blittable struct is not pinned

  • Thread starter Thread starter jackalope_
  • Start date Start date
J

jackalope_

Guest
According to Blittable and Non-Blittable Types(Blittable and Non-Blittable Types), an array of a blittable type is blittable, and a struct that contains only blittable types is also blittable. So an array of blittable struct should be blittable too. So it should be pinned instead of copied when passed to native code via interop.

But check this question(Array of blittable struct not pinned when marshaling?) on StackOverflow. the memory address of the struct certainly changes when being marshaled.

Shame that I can't include any links cos the system says my account is not verified.

Continue reading...
 
Back
Top