原文:a.c:5:5: warning: ignoring return value of ‘scanf’, declared with attribute warn_unused_result [-Wun

PTA做题时出现的错误,用if括起来就没有了。 if scanf d , amp a 其实并不是这里有问题,如果你的输出有问题,他就会鸡蛋里挑骨头的先显示这个错误。 ...

2018-04-15 10:44 0 2179 推荐指数:

查看详情

c++之__attribute__((unused))

转自https://blog.csdn.net/u013083059/article/details/19342935 内核时注意到有些函数会有添加__attribute__((unused)), 在gcc手册中找到了有关的解释: unused ...

Sat Apr 21 19:37:00 CST 2018 0 1067
unused function warning message

這篇的對象是 static function, static function 若沒有其它 function 去存取的話, 在 compile 時,會發生 unused error, 可以在 function 前加上 attribute((unused)) 避免出現 unused error ...

Fri May 04 01:09:00 CST 2018 0 1606
 
粤ICP备18138465号  © 2018-2025 CODEPRJ.COM