1 #include <stdio.h>
2
3 typedef struct test * p_t;
4
5 struct test{char a, b, c,d;};
6
7 int main(void)
8 {
9 int a = 0x12345678;
10
11 printf("a: %x, b: %x, c: %x, d: %x/n", ((p_t)&a)->a,((p_t)&a)->b,((p_t)&a)->c, ((p_t)&a)->d);
12
13 return 0;
14 }
A example of pointer
最新推荐文章于 2025-01-06 22:52:05 发布