From: Pavol Droba (droba_at_[hidden])
Date: 2003-12-15 17:24:34
On Mon, Dec 15, 2003 at 04:29:36PM -0500, Neal D. Becker wrote:
> On Monday 15 December 2003 01:21 pm, Jaakko Jarvi wrote:
> > On Mon, 15 Dec 2003, Neal D. Becker wrote:
> > > I understand from the tuple docs that the default separation character is
> > > space. Is that any whitespace, or only a space character?
> > The default is ' ', or more precisely s.widen(' '), where s is the stream
> > in question.
> > While reading in a tuple from a stream, it is first examined whether
> > the separator character d is a white space character with
> > std::isspace(d, is.getloc())
> > If so, then any other whitespace is accepted as the separator too.
> > If d is not whitespace, the separator can be
> > whitespace* d whitespace*
> Thanks for the info.
> What do you think of my other suggestion, to generalize the classification of
> characters, using a policy?
Why a policy? Simple predicate would be enough. I have already devised a set of classification
predicates for the string algorithm library. These predicates can be also combined
to handle complicated classes. And, of course, a user can always come up with a custom
It is simple and powerful. One would only have to store a predicate (possibly in boost::function)
and use for parsing.
Just my $0.02
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk