Boost logo

Boost :

From: Peter Dimov (pdimov_at_[hidden])
Date: 2002-10-22 11:30:57


From: "Hartmut Kaiser" <hartmutkaiser_at_[hidden]>
>
> [...]
> > So I maintain that it is more natural to just say:
> >
> > nonctl_char = range_p( '\x21', '\xFF' );
> >
> > This would imply that the internal test on range_p() would first
> > transform the arguments to unsigned char.
>
> What about using the following:
>
> inline range<unsigned char>
> urange_p(unsigned char first, unsigned char last)
> { return range<unsigned char>(first, last); }
>
> After what your code looks like:
>
> nonctl_char = urange_p( '\x21', '\xFF' );

The question is, would you ever want ['\x21', '\xFF'] to _not_ be a valid
range?


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