doc: Note that some warnings depend on optimizations (PR 92757)

PR driver/92757
	* doc/invoke.texi (Warning Options): Add caveat about some warnings
	depending on optimization settings.
This commit is contained in:
Jonathan Wakely 2019-12-02 21:32:54 +00:00
parent eb7c7c5245
commit aef85e40e0
2 changed files with 11 additions and 0 deletions

View file

@ -1,3 +1,9 @@
2020-01-13 Jonathan Wakely <jwakely@redhat.com>
PR driver/92757
* doc/invoke.texi (Warning Options): Add caveat about some warnings
depending on optimization settings.
2020-01-13 Jakub Jelinek <jakub@redhat.com>
PR tree-optimization/90838

View file

@ -4575,6 +4575,11 @@ are being produced. This allows the use of new @option{-Wno-} options
with old compilers, but if something goes wrong, the compiler
warns that an unrecognized option is present.
The effectiveness of some warnings depends on optimizations also being
enabled. For example @option{-Wsuggest-final-types} is more effective
with link-time optimization and @option{-Wmaybe-uninitialized} will not
warn at all unless optimization is enabled.
@table @gcctabopt
@item -Wpedantic
@itemx -pedantic