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

           Summary: rvalue binds to ref argument
           Product: D
           Version: D2
          Platform: Other
        OS/Version: Mac OS X
            Status: NEW
          Severity: normal
          Priority: P2
         Component: DMD
        AssignedTo: nob...@puremagic.com
        ReportedBy: and...@metalanguage.com


--- Comment #0 from Andrei Alexandrescu <and...@metalanguage.com> 2011-12-12 
15:42:36 PST ---
I am sure this bug has been filed, but it doesn't have the right keywords so I
couldn't find it. If anyone does, please make that a dupe of this.

struct abc
{
   ref abc opAssign(ref abc rhs)
   {
       writeln("opAssign");
       return this;
   }
}

void
main(string[] argv)
{
   abc x;
   x= abc();
}

The code shouldn't compile. I fished this one from a lost email from June 6,
2010.

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

Reply via email to