結構體相關的計算(結構體指針加一以及強制類型轉換後加一)

定義一個結構體,大小爲16個字節spa struct AAA { long 1A1; char cA2; char cA3; long 1A4; long 1A5; }*p; int main() { p = (struct AAA*)0x100000; printf("%p\n", p + 0x1); printf("%p\n", (unsigned char)p + 0x1);
相關文章
相關標籤/搜索