decl.c (init_decl_processing): Remove bogus initialization.
* decl.c (init_decl_processing): Remove bogus initialization. * error.c (lang_print_error_function): Restore here. (init_error): Initialize print_error_function. From-SVN: r35902
This commit is contained in:
parent
697c2a3964
commit
a72462a4fd
3 changed files with 21 additions and 1 deletions
|
@ -1,3 +1,9 @@
|
|||
2000-08-23 Gabriel Dos Reis <gdr@codesourcery.com>
|
||||
|
||||
* decl.c (init_decl_processing): Remove bogus initialization.
|
||||
* error.c (lang_print_error_function): Restore here.
|
||||
(init_error): Initialize print_error_function.
|
||||
|
||||
2000-08-22 Theodore Papadopoulo <Theodore.Papadopoulo@sophia.inria.fr>
|
||||
|
||||
* decl2.c (arg_assoc): Revert my 2000-08-11 change.
|
||||
|
|
|
@ -6651,7 +6651,6 @@ init_decl_processing ()
|
|||
/* Show we use EH for cleanups. */
|
||||
using_eh_for_cleanups ();
|
||||
|
||||
print_error_function = NULL;
|
||||
valid_lang_attribute = cp_valid_lang_attribute;
|
||||
|
||||
/* Maintain consistency. Perhaps we should just complain if they
|
||||
|
|
|
@ -97,6 +97,7 @@ static void dump_scope PARAMS ((tree, enum tree_string_flags));
|
|||
static void dump_template_parms PARAMS ((tree, int, enum tree_string_flags));
|
||||
|
||||
static const char *function_category PARAMS ((tree));
|
||||
static void lang_print_error_function PARAMS ((const char *));
|
||||
static void maybe_print_instantiation_context PARAMS ((output_buffer *));
|
||||
static void print_instantiation_full_context PARAMS ((output_buffer *));
|
||||
static void print_instantiation_partial_context PARAMS ((output_buffer *, tree,
|
||||
|
@ -152,6 +153,7 @@ init_error ()
|
|||
gcc_obstack_init (&scratch_obstack);
|
||||
scratch_firstobj = (char *)obstack_alloc (&scratch_obstack, 0);
|
||||
|
||||
print_error_function = lang_print_error_function;
|
||||
lang_diagnostic_starter = cp_diagnostic_starter;
|
||||
lang_diagnostic_finalizer = cp_diagnostic_finalizer;
|
||||
}
|
||||
|
@ -2431,6 +2433,19 @@ cv_to_string (p, v)
|
|||
return (char *)obstack_base (&scratch_obstack);
|
||||
}
|
||||
|
||||
static void
|
||||
lang_print_error_function (file)
|
||||
const char *file;
|
||||
{
|
||||
output_state os;
|
||||
|
||||
default_print_error_function (file);
|
||||
os = output_buffer_state (diagnostic_buffer);
|
||||
output_set_prefix (diagnostic_buffer, file);
|
||||
maybe_print_instantiation_context (diagnostic_buffer);
|
||||
output_buffer_state (diagnostic_buffer) = os;
|
||||
}
|
||||
|
||||
static void
|
||||
cp_diagnostic_starter (buffer, dc)
|
||||
output_buffer *buffer;
|
||||
|
|
Loading…
Add table
Reference in a new issue