【发布时间】:2016-01-12 16:45:57
【问题描述】:
下面两个铸件有什么区别吗?
int a=10;
int *p=&a;
(void)p; //does not give any warning or error
或
(void *)p; //error: statement with no effect [-Werror=unused-value]
当遵守gcc -Wall -Werror --std=c99 -pedantic
Just saw that in this answer.(显然我误解了什么)
【问题讨论】: