On 13/09/13 00:15, Jonathan M Davis wrote:
Nope. It's correct. Because it's const, you can't call popFront on it or any
of the other mutating range operations. So, it's not a valid range.

D'oh! :-P

I gave the assert as an example, but this one snuck up on me rather unexpectedly -- I'd got a class method that was something like this:

    auto foo(in size_t n) @safe const nothrow pure
    {
        return buf[n];      // where buf is a size_t[][]
    }

... and it turned out that foo was trying to return a const(size_t[]) rather than a size_t[].

Reply via email to