Boost logo

Boost :

From: Pavol Droba (droba_at_[hidden])
Date: 2006-08-31 11:00:34


Hi,

There are reasons for it.

One of them is the posibility to store result in reference-like container.

Example:
vector<iterator_range<string::iterator> > tokens;
split(tokens, input, token_comress_off);

This way you can have a split without copying overhead. I consider
this functionality interesting enough to make the interface to be
like it is now.

Regards,
Pavol

Philippe Vaucher wrote:
> Of course the code :
>
> split(tokens, input.substr(1), token_compress_off);
>
> Should look like :
>
> split(tokens, input.substr(1), is_any_of("/"), token_compress_on);
>
> Philippe
> _______________________________________________
> Unsubscribe & other changes: http://lists.boost.org/mailman/listinfo.cgi/boost
>


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