www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.bugs - [Issue 1848] New: Another IFTI limitation

reply d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=1848

           Summary: Another IFTI limitation
           Product: D
           Version: 1.025
          Platform: PC
        OS/Version: Windows
            Status: NEW
          Severity: normal
          Priority: P2
         Component: DMD
        AssignedTo: bugzilla digitalmars.com
        ReportedBy: wbaxter gmail.com


module iftibug;

struct Wrap(T) {
    alias T ElemType;
}

void func(I)(Wrap!(I).ElemType a) {

}

void main()
{
    func!(float)(2.0f) // ok


    func(2.0f); // error: 
    //iftibug.d(33): template iftibug.func(I) does not match any template
declaration
    //iftibug.d(33): template iftibug.func(I) cannot deduce template function
from argument types (float)
}

------

Ignore the fact that Wrap!(I).ElemType is just 'I' in this little snippet --
this test case was extracted from some C++ code I'm trying to port where the
situation was not quite so simple.


-- 
Feb 17 2008
parent d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=1848


bugzilla digitalmars.com changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
         Resolution|                            |DUPLICATE




------- Comment #1 from bugzilla digitalmars.com  2008-02-21 01:03 -------


*** This bug has been marked as a duplicate of 1454 ***


-- 
Feb 20 2008