This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

PATCH to sorry


When we restore the buffer state, that includes the value of sorrycount.
So increment it earlier.  Fixes spurious XPASS on g++.robertl/eb17.C.

2001-12-14  Jason Merrill  <jason@redhat.com>

	* diagnostic.c (sorry): Increment sorrycount before saving the
	buffer state.

*** diagnostic.c.~1~	Fri Nov 23 17:27:49 2001
--- diagnostic.c	Fri Dec 14 18:30:55 2001
*************** sorry VPARAMS ((const char *msgid, ...))
*** 1049,1057 ****
    VA_OPEN (ap, msgid);
    VA_FIXEDARG (ap, const char *, msgid);
  
    os = output_buffer_state (diagnostic_buffer);
  
-   ++sorrycount;
    output_set_prefix
      (diagnostic_buffer, context_as_prefix (input_filename, lineno, 0));
    output_printf (diagnostic_buffer, "sorry, not implemented: ");
--- 1049,1057 ----
    VA_OPEN (ap, msgid);
    VA_FIXEDARG (ap, const char *, msgid);
  
+   ++sorrycount;
    os = output_buffer_state (diagnostic_buffer);
  
    output_set_prefix
      (diagnostic_buffer, context_as_prefix (input_filename, lineno, 0));
    output_printf (diagnostic_buffer, "sorry, not implemented: ");

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]