diff options
author | jsm28 <jsm28@138bc75d-0d04-0410-961f-82ee72b054a4> | 2010-10-05 14:28:39 +0000 |
---|---|---|
committer | jsm28 <jsm28@138bc75d-0d04-0410-961f-82ee72b054a4> | 2010-10-05 14:28:39 +0000 |
commit | 24ca3b4e3f701e3f091363cdcdf4a32f13ddea7d (patch) | |
tree | 43c4d6f7a1bd908c7de82db7e4231d62541f883a /gcc/opts.h | |
parent | b88a91b52da9aa8b982c0fbeef3f7d11b10a1b9f (diff) | |
download | gcc-24ca3b4e3f701e3f091363cdcdf4a32f13ddea7d.tar.gz |
* opts-common.c (handle_option, handle_generated_option,
read_cmdline_option, set_option): Add diagnostic_context
parameter. Update calls among these functions.
(set_option): Don't use global_dc.
* opts.c (read_cmdline_options): Pass global_dc to
read_cmdline_option.
(decode_options): Pass global_dc to enable_warning_as_error.
(common_handle_option): Pass global_dc to enable_warning_as_error.
(enable_warning_as_error): Add diagnostic_context parameter.
Document parameters. Don't use global_dc. Pass
diagnostic_context parameter to handle_generated_option.
* opts.h (set_option, handle_option, handle_generated_option,
read_cmdline_option, enable_warning_as_error): Add
diagnostic_context parameter.
* Makefile.in (lto-opts.o): Update dependencies.
* coretypes.h (struct diagnostic_context, diagnostic_context):
Declare here.
* diagnostic.h (diagnostic_context): Don't declare typedef here.
* gcc.c (process_command): Pass global_dc to read_cmdline_option.
* langhooks-def.h (struct diagnostic_context): Don't declare here.
(lhd_print_error_function, lhd_initialize_diagnostics): Declare
using diagnostic_context typedef.
* langhooks.c (lhd_initialize_diagnostics): Declare using
diagnostic_context typedef.
* langhooks.h (struct diagnostic_context): Don't declare here.
(initialize_diagnostics, print_error_function): Declare using
diagnostic_context typedef.
* lto-opts.c: Include diagnostic.h.
(lto_reissue_options): Pass global_dc to set_option. Pass
DK_UNSPECIFIED not 0.
* plugin.c (plugins_internal_error_function): Declare using
diagnostic_context typedef.
* plugin.h (struct diagnostic_context): Don't declare here.
(plugins_internal_error_function): Declare using
diagnostic_context typedef.
c-family:
* c-common.h (struct diagnostic_context): Don't declare here.
(c_common_initialize_diagnostics): Declare using
diagnostic_context typedef.
* c-opts.c (c_common_handle_option): Pass global_dc to
handle_generated_option.
cp:
* cp-tree.h (cxx_print_error_function,
cxx_initialize_diagnostics): Declare using diagnostic_context
typedef.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@164991 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/opts.h')
-rw-r--r-- | gcc/opts.h | 14 |
1 files changed, 9 insertions, 5 deletions
diff --git a/gcc/opts.h b/gcc/opts.h index 2dbccbc79fe..fbfe6bf3447 100644 --- a/gcc/opts.h +++ b/gcc/opts.h @@ -216,19 +216,21 @@ extern bool get_option_state (struct gcc_options *, int, struct cl_option_state *); extern void set_option (struct gcc_options *opts, struct gcc_options *opts_set, - int opt_index, int value, const char *arg, int); + int opt_index, int value, const char *arg, int kind, + 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); + 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, - const struct cl_option_handlers *handlers); + const struct cl_option_handlers *handlers, + diagnostic_context *dc); void generate_option (size_t opt_index, const char *arg, int value, unsigned int lang_mask, struct cl_decoded_option *decoded); @@ -238,10 +240,12 @@ extern void read_cmdline_option (struct gcc_options *opts, struct gcc_options *opts_set, struct cl_decoded_option *decoded, unsigned int lang_mask, - const struct cl_option_handlers *handlers); + const struct cl_option_handlers *handlers, + diagnostic_context *dc); extern void register_warning_as_error_callback (void (*callback) (int)); extern void enable_warning_as_error (const char *arg, int value, unsigned int lang_mask, - const struct cl_option_handlers *handlers); + const struct cl_option_handlers *handlers, + diagnostic_context *dc); extern void print_ignored_options (void); #endif |