Boost logo

Boost :

From: Jonathan Turkanis (technews_at_[hidden])
Date: 2004-08-28 14:41:59


"Daryle Walker" <darylew_at_[hidden]> wrote in message:

> > Daryle can build his own defense on why he included multi_newer.
> > It is cleaner than inserting the same character multiple times.
> > You're right that it's not an improvement over inserting
> > std::string('c', n). The name, of course, is a problem, too.
> [TRUNCATE]
>
> The idea for "multi_newer" just popped into my head. The string solution is
> worse because it forces an extra memory allocation.

I wouldn't use a string in place of a fixed number of repeitions of a given
character. I said this in some other message, but I like

     cout << repeat('c', 17)

Jonathan


Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk