From 77b1a9217b8359f417c7e090e857c464d2e8778a Mon Sep 17 00:00:00 2001 From: Neil Booth Date: Sun, 21 Oct 2001 21:03:48 +0000 Subject: langhooks.c (lang_hook_default_do_nothing, [...]): New defaults. * langhooks.c (lang_hook_default_do_nothing, lang_hook_default_decode_option): New defaults. * langhooks.h: Make hooks unconditional and non-NULL. * toplev.c (compile_file, toplev_main): Update. * toplev.h: Update comments. * objc/objc-act.c (lang_hooks): Update to new paradigm. From-SVN: r46396 --- gcc/objc/objc-act.c | 16 +++++++++++----- 1 file changed, 11 insertions(+), 5 deletions(-) (limited to 'gcc/objc/objc-act.c') diff --git a/gcc/objc/objc-act.c b/gcc/objc/objc-act.c index 9da8ba0..8cf0286 100644 --- a/gcc/objc/objc-act.c +++ b/gcc/objc/objc-act.c @@ -58,6 +58,7 @@ Boston, MA 02111-1307, USA. */ #include "cpplib.h" #include "debug.h" #include "target.h" +#include "langhooks.h" /* This is the default way of generating a method name. */ /* I am not sure it is really correct. @@ -449,12 +450,17 @@ static int generating_instance_variables = 0; static int print_struct_values = 0; +#undef LANG_HOOKS_INIT +#define LANG_HOOKS_INIT objc_init +#undef LANG_HOOKS_INIT_OPTIONS +#define LANG_HOOKS_INIT_OPTIONS objc_init_options +#undef LANG_HOOKS_DECODE_OPTION +#define LANG_HOOKS_DECODE_OPTION objc_decode_option +#undef LANG_HOOKS_POST_OPTIONS +#define LANG_HOOKS_POST_OPTIONS objc_post_options + /* Each front end provides its own. */ -struct lang_hooks lang_hooks = {objc_init, - NULL, /* objc_finish */ - objc_init_options, - objc_decode_option, - objc_post_options}; +struct lang_hooks lang_hooks = LANG_HOOKS_INITIALIZER; /* Post-switch processing. */ static void -- cgit v1.1