[dmd-beta] rvalue references

Masahiro Nakagawa repeatedly at gmail.com
Wed Apr 11 23:11:22 PDT 2012


On Thu, Apr 12, 2012 at 1:06 PM, Sean Kelly <sean at invisibleduck.org> wrote:

> On Apr 10, 2012, at 5:57 PM, Walter Bright wrote:
>
> > I couldn't remember what the big problem was with rvalue references, and
> so I spent some time on the phone talking with Andrei about what exactly
> the problem is. They are:
> >
> > 1.
> > C++:
> >  int i;
> >  double& d = i;
>
> I'm shocked that this is legal.  Why allow implicit conversions when
> assigning to a reference?
>
>
No. In C++, this is ill-formed but MSVC accepts this code...
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.puremagic.com/pipermail/dmd-beta/attachments/20120412/deb547ec/attachment.html>


More information about the dmd-beta mailing list