www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.bugs - [Issue 12731] New: Infinite range slices are not themselves sliceable

https://issues.dlang.org/show_bug.cgi?id=12731

          Issue ID: 12731
           Summary: Infinite range slices are not themselves sliceable
           Product: D
           Version: D2
          Hardware: All
                OS: All
            Status: NEW
          Severity: normal
          Priority: P1
         Component: Phobos
          Assignee: nobody puremagic.com
          Reporter: monarchdodra gmail.com

But they should be:

import std.range;

void main( ) 
{
    auto a = repeat(1);
    auto s = a[1 .. 5]; //OK
    s = s[1 .. 3]; //NOPE
}

--
May 11 2014