[Bug c/86134] earlier diagnostic causes followup diagnostic about unknown -Wno-* options
rguenth at gcc dot gnu.org
gcc-bugzilla@gcc.gnu.org
Wed Jun 13 11:33:00 GMT 2018
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=86134
Richard Biener <rguenth at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Summary|earlier error causes |earlier diagnostic causes
|followup diagnostic about |followup diagnostic about
|unknown -Wno-* options |unknown -Wno-* options
Known to fail| |4.8.5, 8.1.0
--- Comment #1 from Richard Biener <rguenth at gcc dot gnu.org> ---
Also
> echo 'int main(){}' | gcc -S -x c -Wno-unknown-warning-option -Wall -Werror -Wno-error=return-type -
<stdin>: In function ‘main’:
<stdin>:1:1: warning: control reaches end of non-void function [-Wreturn-type]
<stdin>: At top level:
cc1: error: unrecognized command line option "-Wno-unknown-warning-option"
[-Werror]
cc1: all warnings being treated as errors
> echo $?
1
> echo 'int main(){}' | gcc -S -x c -Wno-unknown-warning-option -Wreturn-type -
<stdin>: In function ‘main’:
<stdin>:1:1: warning: control reaches end of non-void function [-Wreturn-type]
<stdin>: At top level:
cc1: warning: unrecognized command line option "-Wno-unknown-warning-option"
[enabled by default]
More information about the Gcc-bugs
mailing list