I want to make the following warnings in gcc into errors, however, I failed to find any documentation on which switches control them, including the -fdiagnostics-show-option
switch.
The warnings are:
deleteing void * is undefined
and
possible problem detected in invocation of delete operator:
'p' has incomplete type
The [enabled by default]
part of the warnings (that you didn't show) indicates that there is no specific warning flag controlling them, so nothing you can use to say -Wno-xxx
or -Werror=xxx
With GCC 4.9 you can use -Werror=delete-incomplete
to control the second one
您可以使用-Werror标记进行编译,以将警告视为错误。
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.