On Monday, May 29, 2017 07:39:40 Dukc via Digitalmars-d wrote:
> But what would be worth a consideration, is that perhaps one
> should be allowed to pass rvalues as reference with something
> like this? According to TDPL, ref arguments do not take rvalues
> to prevent bugs where you accidently copy something before
> passing it, and that's a good rationale. But shouldn't it still
> be allowed explicitly?

I expect that we're going to see a DIP related to rvalue references at some
point here, because some of the folks (particularly the game folks) think
that it's critical to be able to have a function that doesn't care whether
it's taking a value by value or by ref - just that it takes it efficiently,
and they don't want to be forced to use auto ref to do it (since that
requires templates).

- Jonathan M Davis

Reply via email to