Boost logo

Boost :

From: Edward Diener (eddielee_at_[hidden])
Date: 2005-12-19 15:13:09


Eric Niebler wrote:
> Thorsten Ottosen wrote:
>>
>>If I add const to the T() conversion, it suddenly works ok again.
>
>
>
> Yes, that's because for the first line, there are two ways for the
> conversion to succeed. It could call operator T(), or it could call
> operator T&() followed by the standard lvalue-to-rvalue conversion.

Shouldn't operator T() be preferred because operator T&() requires an
extra conversion ?


Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk