I want to convert a byte* to a byte[], but I also want to have a reusable function to do this:
byte*
byte[]
public unsafe static T[] Create
Seems that the question becomes: How to specify a generic Type to be a simple type.
unsafe void Foo() : where T : struct { T* p; }
Gives the error: Cannot take the address of, get the size of, or declare a pointer to a managed type ('T')