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]

C++ PATCH for PR/18644


This implements the agreement in

    http://gcc.gnu.org/ml/gcc/2005-01/msg00118.html

The HTML page change is separate and will follow.
This is against mainline; as it is a regression I would also like to
apply similar change to 3.3.x, 3.4.x and 4.0.x.

-- Gaby

doc/
2005-03-25  Gabriel Dos Reis  <gdr@integrable-solutions.net>
 
 	PR c++/18644
 	* doc/invoke.texi (-Wsynth): Don't document, as it now is void of
 	semantics. 

cp/
2005-03-25  Gabriel Dos Reis  <gdr@integrable-solutions.net>

	PR c++/18644
	* call.c (build_new_op): Remove check for -Wsynth.

Index: cp/call.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/cp/call.c,v
retrieving revision 1.531
diff -p -r1.531 call.c
*** cp/call.c	24 Feb 2005 21:55:10 -0000	1.531
--- cp/call.c	26 Mar 2005 04:53:58 -0000
*************** build_new_op (enum tree_code code, int f
*** 3750,3769 ****
  	  if (overloaded_p)
  	    *overloaded_p = true;
  
- 	  if (warn_synth
- 	      && fnname == ansi_assopname (NOP_EXPR)
- 	      && DECL_ARTIFICIAL (cand->fn)
- 	      && candidates->next
- 	      && ! candidates->next->next)
- 	    {
- 	      warning ("using synthesized %q#D for copy assignment",
- 			  cand->fn);
- 	      cp_warning_at ("  where cfront would use %q#D",
- 			     cand == candidates
- 			     ? candidates->next->fn
- 			     : candidates->fn);
- 	    }
- 
  	  result = build_over_call (cand, LOOKUP_NORMAL);
  	}
        else
--- 3750,3755 ----
Index: doc/invoke.texi
===================================================================
RCS file: /cvs/gcc/gcc/gcc/doc/invoke.texi,v
retrieving revision 1.594
diff -p -r1.594 invoke.texi
*** doc/invoke.texi	23 Mar 2005 19:10:01 -0000	1.594
--- doc/invoke.texi	26 Mar 2005 04:54:06 -0000
*************** in the following sections.
*** 188,194 ****
  -Weffc++  -Wno-deprecated @gol
  -Wno-non-template-friend  -Wold-style-cast @gol
  -Woverloaded-virtual  -Wno-pmf-conversions @gol
! -Wsign-promo  -Wsynth}
  
  @item Objective-C and Objective-C++ Language Options
  @xref{Objective-C and Objective-C++ Dialect Options,,Options Controlling
--- 188,194 ----
  -Weffc++  -Wno-deprecated @gol
  -Wno-non-template-friend  -Wold-style-cast @gol
  -Woverloaded-virtual  -Wno-pmf-conversions @gol
! -Wsign-promo}
  
  @item Objective-C and Objective-C++ Language Options
  @xref{Objective-C and Objective-C++ Dialect Options,,Options Controlling
*************** enumerated type to a signed type, over a
*** 1794,1806 ****
  the same size.  Previous versions of G++ would try to preserve
  unsignedness, but the standard mandates the current behavior.
  
- @item -Wsynth @r{(C++ only)}
- @opindex Wsynth
- @cindex warning for synthesized methods
- @cindex synthesized methods, warning
- Warn when G++'s synthesis behavior does not match that of cfront.  For
- instance:
- 
  @smallexample
  struct A @{
    operator int ();
--- 1794,1799 ----



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