Okay, this makes sense, although from my read of the code I think that the PrimitiveDecode API might be a bit broken, b/c it looks like it *will* accept non-pointer structs and will write into them just fine, only to have the data go out of scope when the function exits.

For now I think we should explicitly check to make sure v contains a pointer, and if it doesn't we should return a suitable error, rather than panicking on L23 as would currently happen.