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

           Summary: [qtd] Static members imported with "alias this" are
                    inaccessible
           Product: D
           Version: D2
          Platform: Other
        OS/Version: Linux
            Status: NEW
          Severity: normal
          Priority: P2
         Component: DMD
        AssignedTo: nob...@puremagic.com
        ReportedBy: samu...@voliacable.com


--- Comment #0 from Max Samukha <samu...@voliacable.com> 2011-02-20 08:49:26 
PST ---
class A
{
    enum E
    {
        value
    }

    alias E.value value;

    static void foo()
    {
    }
}

class B
{
    A a;
    alias a this;
}

void main()
{
    enum v = B.E.value;
    enum v2 = B.value;
    B.foo();
}

Error: 'this' is only defined in non-static member functions, not main

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

Reply via email to