On Friday 03 December 2010 22:42:06 Don wrote: > (1) Should temporaries be allowed to be passed as 'const ref'?
I honestly do not understand why they can't be already. C++ definitely allows this. Is there something bad about it? I'd probably use const ref a lot more, but because it will only take lvalues, it's _highly_ limiting. If you could overload functions on ref (I _think_ that there's a bug on that), then you could have two versions of opEquals - with with const ref and one which would copy the value - but ideally, you'd only need the one with const ref. - Jonathan M Davis