Ctypes definition
How could I write the definition copied bellow using c开发者_StackOverflow社区types?
unsigned char* x = new unsigned char[10];
Thank you.
Depending on how you need to use x
, you probably want ctypes.create_string_buffer
.
x = ctypes.create_string_buffer(' ' * 10);
精彩评论