开发者

how to disable specific warning when -Wall is enabled

I have used -Wall -Werror in my Makefile but I want to disable following specific type of warning :

 warning: '_wrap_delete_DMXTSFILTER' defined开发者_开发百科 but not used

How shoud I do that?


This way


Assuming it's unused variable:

-Wno-unused-variable


Finnaly, I used this trick __attribute__((unused)). The advantage is I could apply it to individual functions / variables instead of the whole source file which the -Wno-unsed-xxxxx will apply on.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜