-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path1
More file actions
37 lines (32 loc) · 603 Bytes
/
1
File metadata and controls
37 lines (32 loc) · 603 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
typedef unsigned int GEN_OBJ_T[7];
typedef enum
{
A, B, C, D, E, F, G, H, AUTO = 30, UNKNOW
} COLOR_SYS_T;
#pragma pack(4)
typedef struct
{
union
{
unsigned char u_char;
COLOR_SYS_T u_sys_type;
unsigned long int u_long_int : 24;
signed long long _long : 16;
int u_int[96 / UNKNOW];
}u;
}GEN_SUB_OBJ_T;
#pragma pack()
typedef struct _my_obj_t
{
signed char a;
GEN_OBJ_T obj;
GEN_SUB_OBJ_T sub_obj;
struct _my_obj_t* next;
struct _my_obj_t* prev;
}MY_OBJ_T;
int main(int argc, char* argv[])
{
cout << sizeof(MY_OBJ_T) << endl;
cout << sizeof(GEN_SUB_OBJ_T) << endl;
return 0;
}