diff options
author | jsm28 <jsm28@138bc75d-0d04-0410-961f-82ee72b054a4> | 2010-11-12 23:26:56 +0000 |
---|---|---|
committer | jsm28 <jsm28@138bc75d-0d04-0410-961f-82ee72b054a4> | 2010-11-12 23:26:56 +0000 |
commit | 3c6c0e40fd80e2cd4909ef171f9a92efb5c6f348 (patch) | |
tree | ac9656c3417bd52665bd19c9ce7e400c0cee83d4 /gcc/opts.h | |
parent | cb74576fd7fb513113b0600ce43d689ff54b6684 (diff) | |
download | gcc-3c6c0e40fd80e2cd4909ef171f9a92efb5c6f348.tar.gz |
* Makefile.in (OPTS_H): Define.
(c-decl.o, c-family/c-common.o, c-family/c-opts.o,
c-family/c-pch.o, c-family/c-pragma.o, gcc.o, gccspec.o,
cppspec.o, options.o, gcc-options.o, lto-opts.o, opts.o,
opts-common.o, toplev.o, passes.o, matrix-reorg.o,
ipa-struct-reorg.o, PLUGIN_HEADERS): Use $(OPTS_H).
* gcc.c (driver_handle_option): Take location_t parameter.
(process_command, do_self_spec): Update calls to
read_cmdline_option.
* langhooks-def.h (lhd_handle_option): Take location_t parameter.
* langhooks.c (lhd_handle_option): Take location_t parameter.
* langhooks.h (handle_option): Take location_t parameter.
* lto-opts.c (lto_reissue_options): Update call to set_option.
* opts-common.c (handle_option): Make static. Take location_t
parameter and pass it to other functions.
(handle_generated_option): Take location_t parameter and pass it
to other functions.
(read_cmdline_option): Take location_t parameter and pass it to
other functions. Use warning_at and error_at.
(set_option): Take location_t parameter and pass it to other
functions.
* opts.c (common_handle_option): Take location_t parameter and
pass it to other functions.
(enable_warning_as_error): Make static. Take location_t parameter
and pass it to other functions.
(lang_handle_option): Take location_t parameter and pass it to
other functions.
(target_handle_option): Take location_t parameter.
(read_cmdline_options, maybe_default_option,
maybe_default_options, default_options_optimization,
decode_options): Take location_t parameter and pass it to other
functions.
* opts.h: Include input.h.
(struct cl_option_handler_func, decode_options, set_option,
handle_generated_option, read_cmdline_option): Take location_t
parameters.
(handle_option, enable_warning_as_error): Remove.
* toplev.c (toplev_main): Update call to decode_options.
ada:
* gcc-interface/Make-lang.in (ada/misc.o): Use $(OPTS_H).
* gcc-interface/misc.c (gnat_handle_option): Take location_t
parameter.
c-family:
* c-common.c (parse_optimize_options): Update call to
decode_options.
* c-common.h (c_common_handle_option): Update prototype.
* c-opts.c (c_common_handle_option): Take location_t parameter and
pass it to other functions.
cp:
* Make-lang.in (g++spec.o): Use $(OPTS_H).
fortran:
* Make-lang.in (gfortranspec.o): Use $(OPTS_H).
* gfortran.h (gfc_handle_option): Take location_t parameter.
* options.c (gfc_handle_option): Take location_t parameter.
java:
* Make-lang.in (jvspec.o, java/lang.o): Use $(OPTS_H).
* lang.c (java_handle_option): Take location_t parameter.
lto:
* Make-lang.in (lto/lto.o): Use $(OPTS_H).
* lto-lang.c (lto_handle_option): Take location_t parameter.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@166688 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/opts.h')
-rw-r--r-- | gcc/opts.h | 20 |
1 files changed, 7 insertions, 13 deletions
diff --git a/gcc/opts.h b/gcc/opts.h index 069333b7f74..9d5ecb36c84 100644 --- a/gcc/opts.h +++ b/gcc/opts.h @@ -21,6 +21,8 @@ along with GCC; see the file COPYING3. If not see #ifndef GCC_OPTS_H #define GCC_OPTS_H +#include "input.h" + /* Specifies how a switch's VAR_VALUE relates to its FLAG_VAR. */ enum cl_var_type { /* The switch is enabled when FLAG_VAR is nonzero. */ @@ -164,7 +166,7 @@ struct cl_option_handler_func bool (*handler) (struct gcc_options *opts, struct gcc_options *opts_set, const struct cl_decoded_option *decoded, - unsigned int lang_mask, int kind, + unsigned int lang_mask, int kind, location_t loc, const struct cl_option_handlers *handlers, diagnostic_context *dc); @@ -225,6 +227,7 @@ extern void decode_options (struct gcc_options *opts, struct gcc_options *opts_set, struct cl_decoded_option *decoded_options, unsigned int decoded_options_count, + location_t loc, diagnostic_context *dc); extern int option_enabled (int opt_idx, void *opts); extern bool get_option_state (struct gcc_options *, int, @@ -232,18 +235,12 @@ extern bool get_option_state (struct gcc_options *, int, extern void set_option (struct gcc_options *opts, struct gcc_options *opts_set, int opt_index, int value, const char *arg, int kind, - diagnostic_context *dc); + location_t loc, diagnostic_context *dc); extern void *option_flag_var (int opt_index, struct gcc_options *opts); -bool handle_option (struct gcc_options *opts, - struct gcc_options *opts_set, - const struct cl_decoded_option *decoded, - unsigned int lang_mask, int kind, - const struct cl_option_handlers *handlers, - bool generated_p, diagnostic_context *dc); bool handle_generated_option (struct gcc_options *opts, struct gcc_options *opts_set, size_t opt_index, const char *arg, int value, - unsigned int lang_mask, int kind, + unsigned int lang_mask, int kind, location_t loc, const struct cl_option_handlers *handlers, diagnostic_context *dc); void generate_option (size_t opt_index, const char *arg, int value, @@ -254,12 +251,9 @@ void generate_option_input_file (const char *file, extern void read_cmdline_option (struct gcc_options *opts, struct gcc_options *opts_set, struct cl_decoded_option *decoded, + location_t loc, unsigned int lang_mask, const struct cl_option_handlers *handlers, diagnostic_context *dc); -extern void enable_warning_as_error (const char *arg, int value, - unsigned int lang_mask, - const struct cl_option_handlers *handlers, - diagnostic_context *dc); extern void print_ignored_options (void); #endif |