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

           Summary: opDispatch must be considered before alias this.
           Product: D
           Version: D2
          Platform: All
        OS/Version: All
            Status: NEW
          Severity: major
          Priority: P2
         Component: DMD
        AssignedTo: nob...@puremagic.com
        ReportedBy: g...@boloneum.com


--- Comment #0 from Gor Gyolchanyan <g...@boloneum.com> 2011-08-03 06:14:26 PDT 
---
When a class or struct has an opDispatch and an alias this, the alias this is
considered first and a member access gives "no such property" error:

struct A
{
   Variant i;
   alias i this;

   void opDispatch(string name)()
   {
   }
}

unittest
{
   A a;
   a.weird; // no property 'weird' for type 'VariantN!(maxSize)'
}

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

Reply via email to