PR [C/C++/Fortran/Java] 28875 "-Wextra -Wno-unused-parameter -Wall" doesn't work as expected
Manuel López-Ibáñez
lopezibanez@gmail.com
Fri Aug 8 11:09:00 GMT 2008
This fixes 28875 and makes the whole handling of Wunused much less complicated.
Bootstrapped and regression tested on x86_64-unknown-linux-gnu with
--enable-languages=all.
OK for trunk?
2008-08-08 Manuel Lopez-Ibanez <manu@gcc.gnu.org>
PR 28875
* flags.h (set_Wunused): Delete
* toplev.c (process_options): Handle Wunused flags here.
* opts.c (maybe_warn_unused_parameter): Delete.
(common_handle_option): Replace set_Wunused by warn_unused.
(set_Wextra): Do not handle Wunused-parameter here.
(set_Wunused): Delete.
* c-opts.c (c_common_handle_option): Replace set_Wunused by
warn_unused.
* common.opt (Wunused): Add Var and Init.
(Wunused-function): Likewise.
(Wunused-label): Likewise.
(Wunused-parameter): Likewise.
(Wunused-value): Likewise.
(Wunused-variable): Likewise.
fortran/
* options.c (set_Wall): Replace set_Wunused by warn_unused.
java/
* lang.c (java_handle_option): Replace set_Wunused with
warn_unused.
testsuite/
* gcc.dg/unused-6-no.c: New.
* gcc.dg/unused-6-WallWextra.c: New.
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: fix-pr28875.diff
URL: <http://gcc.gnu.org/pipermail/fortran/attachments/20080808/b21a9cd6/attachment.ksh>
More information about the Fortran
mailing list