如何将以下内容转换struct
为unsigned char*
?
typedef struct {
unsigned char uc1;
unsigned char uc2;
unsigned char uc3;
unsigned char uc5;
unsigned char uc6;
} uchar_t;
uchar_t *uc_ptr = new uchar;
unsigned char * uc_ptr2 = static_cast<unsigned char*>(*uc_ptr);
// invalid static cast at the previous line