[patch] : more delegation in stl_algo.h

Paolo Carlini pcarlini@suse.de
Mon Mar 14 10:45:00 GMT 2005


Chris Jefferson wrote:

> Apart from that, this patch is hopefully mostly fairly obvious, with 
> the exception that replace_copy of used to have a construct "z = p ? x 
> : y" which I've replaced with "if(z) p=x else p=y", as in theory x and 
> y can be of different types, neither convertable to the other but both 
> convertable to typeof(z).

For now, I have added the below: testcases + minor tweaks + fix to 
replace_copy & replace_copy_if (fixed the check_type testcase of the 
latter).

I'm afraid, a complete solution for the empty struct issue is not beyond 
the corner, therefore we should deal first with search/search_n, making 
sure that we don't regress performance-wise wrt mainline. Probably, I 
will do some benchmarks. Only later, hopefully, proceed with more 
delegations.

Seems also a nice idea porting the complete set of testcases for 
<algorithm> (+ minor tweaks) to mainline: if nobody objects will do soon.

Paolo.

///////////////
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: ChangeLog-ot
URL: <http://gcc.gnu.org/pipermail/libstdc++/attachments/20050314/908987fb/attachment.ksh>
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: patch-ot
URL: <http://gcc.gnu.org/pipermail/libstdc++/attachments/20050314/908987fb/attachment-0001.ksh>


More information about the Libstdc++ mailing list