rvalue references

Namespace via Digitalmars-d digitalmars-d at puremagic.com
Thu May 14 13:09:53 PDT 2015


On Thursday, 14 May 2015 at 20:02:29 UTC, bitwise wrote:
> On Thu, 14 May 2015 13:15:34 -0400, Namespace 
> <rswhite4 at gmail.com> wrote:
>> On Thursday, 14 May 2015 at 16:53:04 UTC, bitwise wrote:
>>> If it were up to me, I would say:
>>>
>>> 'scope' should be removed as a storage class,
>>> 'ref' should be left as is, and
>>> 'in' should adopt the behavior of 'ref' post DIP25
>>>
>>>  Bit
>>
>> As Andrei said several times (recently here: 
>> http://forum.dlang.org/thread/scaufixfdyyrbmijgitf@forum.dlang.org?page=3#post-mit5lp:241kpt:241:40digitalmars.com) 
>> auto ref will take care about rvalue references. I've only 
>> hoped that I could get a schedule for that or at least a 
>> confirmation. :)
>
>
> If I understand Andrei's response correctly though, you will 
> still have to
> use 'auto ref' to get ref to bind to rvalues.. no?
Yes, that's what I said. :)
Besides, it would be horrible if rvalues could be bound to normal 
ref.

> So if I'm right about the above, and scope is out, why not just 
> use 'in' instead of 'auto ref'?
>
>     Bit

Don't ask me, I'm just a little light here.


More information about the Digitalmars-d mailing list