auto ref - again

deadalnix deadalnix at gmail.com
Sat Jan 26 20:38:43 PST 2013


On Sunday, 27 January 2013 at 02:28:26 UTC, Era Scarecrow wrote:
>  Having ref accept rValues seems like a bad idea. If the source 
> is const/immutable then it might be allowed, but more likely 
> temporaries will be made for convertion from rValues to 
> lValues, then passing off the temporaries. The temporaries to 
> work right likely need to be at the top-most scope of whatever 
> function you happen to be in; Beyond that I'm not sure how else 
> the auto ref could be implemented safely.

I have yet to see an instance of such problem in real life, but 
quite frankly, I tired to argue.


More information about the Digitalmars-d mailing list