文章详情

  • 游戏榜单
  • 软件榜单
关闭导航
热搜榜
热门下载
热门标签
php爱好者> php文档>C语言中的undefined behavior系列(5) -- not compatible type

C语言中的undefined behavior系列(5) -- not compatible type

时间:2010-08-31  来源:嗷嗷

— Two declarationsof the same object or function specify types that are not compatible(6.2.7).

    char c = 'a';
char *pc = &c;
int *pi;
void *pv;
pi
= pv = pc; //这里没有编译错误或警告
//pv = pi =pc; //这样写的话会有一个warning a value of type "char *" cannot be assigned to an entity of type "int *"
*pi = 10; //undefined behavior

 

 

 

相关阅读 更多 +
排行榜 更多 +
幸运硬币官方正版下载

幸运硬币官方正版下载

休闲益智 下载
宝宝来找茬手机版 v9.86.00.00 安卓版

宝宝来找茬手机版 v9.86.00.00 安卓版

休闲益智 下载
翻滚飞机大战最新版 v1.0.4 安卓版

翻滚飞机大战最新版 v1.0.4 安卓版

飞行射击 下载