www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.bugs - [Issue 20877] New: Type deduction doesn't work for Alias Template

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

          Issue ID: 20877
           Summary: Type deduction doesn't work for Alias Template
                    Parameters
           Product: D
           Version: D2
          Hardware: All
                OS: All
            Status: NEW
          Keywords: rejects-valid
          Severity: normal
          Priority: P1
         Component: dmd
          Assignee: nobody puremagic.com
          Reporter: b2.temp gmx.com

The addition brought by https://github.com/dlang/dmd/pull/9769 didn't handle
all the details. while specialization should work now (since
https://github.com/dlang/dmd/pull/11193), deduction based on specialization is
still missing.

test case:

---
void main()
{
    void foo(alias T: int)(T t){}
    foo(1);
}
---

--
May 29