www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.bugs - [Issue 14032] New: [ICE](mtype.c line 154) with std.algorithm.tee

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

          Issue ID: 14032
           Summary: [ICE](mtype.c line 154) with std.algorithm.tee
           Product: D
           Version: D2
          Hardware: x86
                OS: Windows
            Status: NEW
          Severity: enhancement
          Priority: P1
         Component: DMD
          Assignee: nobody puremagic.com
          Reporter: bearophile_hugs eml.cc

int foo()() { return 1; }
void main() {
    import std.algorithm: tee;
    [1].tee!foo;
}


dmd2.067alpha gives:


...\dmd2\src\phobos\std\range\package.d(8194,22): Error: template instance
fun!int does not match template declaration foo()()
Assertion failure: 'false' on line 154 in file 'mtype.c'

--
Jan 23 2015