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]

Re: [C++ PATCH] Fix 21280


DJ Delorie wrote:
Nathan Sidwell <nathan@codesourcery.com> writes:

When tweaking the patch so it applied to mainline, I realised the new
error message should really be a warning.  So this is how I've amended
the 4.0 branch.

   if (error_count != errorcount || warning_count != warningcount)
!     warning ("%Hsynthesized method %qD first required here ",
! 	     &input_location, fndecl);


Note that this doesn't compile on mainline.
arg!

it does with this,

nathan
--
Nathan Sidwell    ::   http://www.codesourcery.com   ::     CodeSourcery LLC
nathan@codesourcery.com    ::     http://www.planetfall.pwp.blueyonder.co.uk

Index: cp/method.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/cp/method.c,v
retrieving revision 1.331
diff -c -3 -p -r1.331 method.c
*** cp/method.c	2 Jun 2005 17:52:12 -0000	1.331
--- cp/method.c	2 Jun 2005 20:01:31 -0000
*************** synthesize_method (tree fndecl)
*** 806,812 ****
    pop_deferring_access_checks ();
  
    if (error_count != errorcount || warning_count != warningcount)
!     warning ("%Hsynthesized method %qD first required here ",
  	     &input_location, fndecl);
  }
  
--- 806,812 ----
    pop_deferring_access_checks ();
  
    if (error_count != errorcount || warning_count != warningcount)
!     warning (0, "%Hsynthesized method %qD first required here ",
  	     &input_location, fndecl);
  }
  

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