2025-05-18 09:11:15 +08:00

3 lines
139 B
C

#define offsetof(type, struct_name) (size_t)&(((struct type*)0)->struct_name)
// 计算结构体成员相对结构体首地址的偏移度