Replacing string += "." by '.'

Benjamin Kosnik bkoz@redhat.com
Mon Nov 25 10:37:00 GMT 2002


>triggered by a recent patch of Paolo, I thought about the implications of 
>replacing adding single characters like
>  __str += '=';
>by
>  __str += "=";
>
>It seemed to me that the latter is more expensive.

Absolutely. I was a bit surprised to see this as well.

-benjamin



More information about the Libstdc++ mailing list