Subject: Re: [boost] Iterator Range and operator==
From: Andrey Semashev (andrey.semashev_at_[hidden])
Date: 2012-04-21 16:45:49
On Saturday 21 April 2012 21:01:06 Neil Groves wrote:
> > > You mean, so that raw built-in arrays would cease to be ranges at all?
> > > I guess that's a possiblity. Nobody thought about that, IIRC.
> I did consider doing this with the RangeEx upgrade. I rejected the idea on
> the basis that the as_array idiom did not always fully optimize away on
> lesser compilers and the syntactic mess was unpleasant.
Out of curiosity, what exactly was the runtime overhead of using as_array?
IMHO, if a compiler is not able to inline it, it's not worth using.
As for the syntactic sugar, the example Olaf provided in the beginning of this
thread clearly would benefit from an explicit specification, whether a literal
or an array should be used.