Boost logo

Boost :

From: Peter Dimov (pdimov_at_[hidden])
Date: 2004-05-07 11:58:52

David Abrahams wrote:
> "Peter Dimov" <pdimov_at_[hidden]> writes:
>> John Torjo wrote:
>>>> I agree. IMO the best answer for now is to generate the 2^N
>>>> overloads of operator() for some user-selectable N. Unary and
>>>> binary functions are so common that IMO usually N==2 will do it.
>>> I second that. Maybe n==3 anyone?
>> Many older compilers have problems with T& / T const & overloading,
>> even if they support partial ordering.
> Which ones?

I'm not sure, it's been a while. I recall that EDG 2.40 and earlier couldn't
order the two templates (in the const lvalue case, ordinary overloading
rules apply otherwise); there may be others.

> Don't some also bind temps to T& when that's all you supply?

Borland and MSVC 6 do that, with a warning.

Boost list run by bdawes at, gregod at, cpdaniel at, john at