www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.bugs - [Issue 11855] New: Explicit template instantiation with opDispatch fails to compile

https://d.puremagic.com/issues/show_bug.cgi?id=11855

           Summary: Explicit template instantiation with opDispatch fails
                    to compile
           Product: D
           Version: D2
          Platform: All
        OS/Version: All
            Status: NEW
          Severity: normal
          Priority: P2
         Component: DMD
        AssignedTo: nobody puremagic.com
        ReportedBy: doob me.com



The following code fails to compile:

struct Foo
{
    void opDispatch (string name, T) () { }
}

void main ()
{
    Foo foo;
    foo.bar!(int);
}

The error message is:

Error: no property 'bar' for type 'Foo'

-- 
Configure issuemail: https://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
Jan 01 2014