|
Boost : |
From: Vladimir Prus (ghost_at_[hidden])
Date: 2003-02-07 05:29:57
Dave Abrahams wrote:
>>there's a serious problem with it. It includes another one, which
>>declares find_if algorithm in namespace boost, and that causes ambiguity
>>with std::find_if. The following code piece illustrates it
....
>>}
>>
>>The situation is that implementation of std::remove_if calls find_if
>>(not std::find_if). Thanks to argument-dependent lookup (the predicate
>>is from boost namespace), boost::find_if is found, and ambiguity arises.
>>(This all happens with g++ 3.2).
>>
>>So, what is it? A bug in standard library? A problem with the standard?
>
>
> Many of us think it is both. Some people <ahem> on the GCC team have been
> reluctant to fix it until they got a firm declaration from the LWG that it
> was a bug, and now they are about to:
> http://anubis.dkuug.dk/jtc1/sc22/wg21/docs/lwg-active.html#229
Thanks for clarification.
>> Or, providing another find_if in namespace boost can never work?
>
>
> Not with GCC-3.2! Welcome to the wonderful world of ADL!
:-(
But this means that sequence_algo/algorith.hpp is almost completely unusable
for me as it is. I think that the simples solution is to eliminate the
problematic include. Are there any downsides?
- Volodya
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk