[Issue 14076] New: Partial type deduction doesn't work with lambdas

via Digitalmars-d-bugs digitalmars-d-bugs at puremagic.com
Thu Jan 29 05:45:53 PST 2015


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

          Issue ID: 14076
           Summary: Partial type deduction doesn't work with lambdas
           Product: D
           Version: D2
          Hardware: All
                OS: All
            Status: NEW
          Keywords: rejects-valid
          Severity: normal
          Priority: P1
         Component: DMD
          Assignee: nobody at puremagic.com
          Reporter: k.hara.pg at gmail.com

Test case:

immutable pure @safe bool function(in bool[])[2] a481_19x =
[
    s => s[0],
    s => s[0]
];
immutable pure @safe bool function(in bool[])[$] a481_19y =  // doesn't work
[
    s => s[0],
    s => s[0]
];
static assert(is(typeof(a481_19x) == typeof(a481_19y)));

--


More information about the Digitalmars-d-bugs mailing list