使用前必须进行强制类型转换
#include <stdio.h> void test(const void *p); int main(){ int i = 123; int *p = &i; puts("my test:"); test(p); } void test(const void *p){ const int *a = (const int *)p; printf("%d ", *a); }