[Issue 3673] New: inheritance + if clause = no go

d-bugmail at puremagic.com d-bugmail at puremagic.com
Mon Jan 4 11:34:01 PST 2010


http://d.puremagic.com/issues/show_bug.cgi?id=3673

           Summary: inheritance + if clause = no go
           Product: D
           Version: unspecified
          Platform: Other
        OS/Version: Linux
            Status: NEW
          Severity: normal
          Priority: P2
         Component: DMD
        AssignedTo: nobody at puremagic.com
        ReportedBy: andrei at metalanguage.com


--- Comment #0 from Andrei Alexandrescu <andrei at metalanguage.com> 2010-01-04 11:34:00 PST ---
This code should compile:

interface OutputRange(T...) if (T.length == 1)
{
    void put(T[0] value);
}

interface OutputRange(T...) : OutputRange!(T[0]), OutputRange!(T[1 .. $])
                              if (T.length > 1)
{
}

The first error is "members expected" upon the "if" clause in the second
definition, which suggests that the syntax is not yet supported.

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


More information about the Digitalmars-d-bugs mailing list