Thanks for the reply.
And indeed, I recently found that ByLine.empty can't be const
because it writes and removes a character from the stream or
something... and when I compile with optimizations, const empty
gets totally wrecked.
I suppose that making empty const doesn't really gain me
any
On Monday, 1 September 2014 at 03:45:25 UTC, Vlad Levenfeld wrote:
I notice that some of the range adapters in std.range (iota,
takeExactly) have a const empty property, while others (take,
retro) don't. This makes maintaining const-correctness
downstream (with my own range adapters atop phobos
I notice that some of the range adapters in std.range (iota,
takeExactly) have a const empty property, while others (take,
retro) don't. This makes maintaining const-correctness downstream
(with my own range adapters atop phobos') more difficult. I'm
wondering if there is a rationale for this,