aboutsummaryrefslogtreecommitdiff
path: root/gcc/fortran/options.c
diff options
context:
space:
mode:
authorManuel López-Ibáñez <manu@gcc.gnu.org>2012-05-11 12:23:50 +0000
committerManuel López-Ibáñez <manu@gcc.gnu.org>2012-05-11 12:23:50 +0000
commit7d5a5747fc5ffbd86d1da0e2cff9823f0446a907 (patch)
tree1a38b4f6902dc5e5cc35971539a25051202efa2e /gcc/fortran/options.c
parent319e6439f592285e7d931c47285c363cca113788 (diff)
downloadgcc-7d5a5747fc5ffbd86d1da0e2cff9823f0446a907.zip
gcc-7d5a5747fc5ffbd86d1da0e2cff9823f0446a907.tar.gz
gcc-7d5a5747fc5ffbd86d1da0e2cff9823f0446a907.tar.bz2
re PR c/53063 (encode group options in the .opt files)
2012-05-11 Manuel López-Ibáñez <manu@gcc.gnu.org> PR 53063 gcc/ * doc/options.texi (EnabledBy): Document * opts.c: Include opts.h and options.h before tm.h. (finish_options): Do not handle some sub-options here... (common_handle_option): ... instead call common_handle_option_auto here. * optc-gen.awk: Handle EnabledBy. * opth-gen.awk: Declare common_handle_option_auto. * common.opt (Wuninitialized): Use EnabledBy. Delete Init. (Wmaybe-uninitialized): Likewise. (Wunused-but-set-variable): Likewise. (Wunused-function): Likewise. (Wunused-label): Likewise. (Wunused-value): Likewise. (Wunused-variable): Likewise. * opt-read.awk: Create opt_numbers array. ada/ * gcc-interface/misc.c (gnat_parse_file): Move before ... (gnat_handle_option): ... this. Use handle_generated_option. c-family/ * c-opts.c (c_common_handle_option): Use handle_generated_option to enable sub-options. fortran/ * options.c: Include diagnostics.h instead of diagnostics-core.h. (set_Wall): Do not see warn_unused here. (gfc_handle_option): Set it here using handle_generated_option. From-SVN: r187403
Diffstat (limited to 'gcc/fortran/options.c')
-rw-r--r--gcc/fortran/options.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/gcc/fortran/options.c b/gcc/fortran/options.c
index dde7ff2..32a8a4c 100644
--- a/gcc/fortran/options.c
+++ b/gcc/fortran/options.c
@@ -34,7 +34,7 @@ along with GCC; see the file COPYING3. If not see
#include "gfortran.h"
#include "target.h"
#include "cpp.h"
-#include "diagnostic-core.h" /* For sorry. */
+#include "diagnostic.h" /* For global_dc. */
#include "tm.h"
gfc_option_t gfc_option;
@@ -474,7 +474,6 @@ set_Wall (int setting)
gfc_option.warn_real_q_constant = setting;
gfc_option.warn_unused_dummy_argument = setting;
- warn_unused = setting;
warn_return_type = setting;
warn_switch = setting;
warn_uninitialized = setting;
@@ -612,6 +611,10 @@ gfc_handle_option (size_t scode, const char *arg, int value,
break;
case OPT_Wall:
+ handle_generated_option (&global_options, &global_options_set,
+ OPT_Wunused, NULL, value,
+ gfc_option_lang_mask (), kind, loc,
+ handlers, global_dc);
set_Wall (value);
break;