go through an intermediate type conversion to unsafe.Pointer, but to my
beginner surprise this works:
var x byte
C.f1( (*C.uint8_t)(&x), 5, ... )
C.f2( (*C.uchar)(&x), 5, ... )
Is it because C.uint8_t and C.uchar are aliases for byte? Something else?
And I assume it's safe to pass a Go byte buffer like this to a C function to directly fill it out with data, correct? I don't need to C.malloc (and later C.free) a C buffer and then copy from it or use C.GoBytes
You received this message because you are subscribed to the Google Groups "golang-nuts" group.
To unsubscribe from this group and stop receiving emails from it, send an email to firstname.lastname@example.org.
For more options, visit https://groups.google.com/d/optout.