rvalue references
Zach the Mystic
reachzach at gggggmail.com
Fri Apr 26 16:55:42 PDT 2013
On Friday, 26 April 2013 at 21:21:50 UTC, Diggory wrote:
>> You're just asking for bugs if you allow ref to accept
>> rvalues. We've had problems like this before when some
>> literals were treated as lvalues. The behavior of a function
>> which takes its argument by ref and the behavior of one which
>> takes its argument by auto ref are fundamentally different.
>
> The only purpose of rvalue references is to allow the callee to
> mutate the value... Otherwise you would just use a const ref.
The forum I'm using suggests that your post was written in
response to me, although it is not my writing!
More information about the Digitalmars-d
mailing list