Just by including: "boost/thread.hpp", which includes "boost/bind.hpp" you pollute the namespace. If you also use Boost.Lambda, you must change _1 to boost::lambda::_1. Is this going to be fixed? Any workarounds?
anony <janezz55 <at> gmail.com> writes:
Just by including: "boost/thread.hpp", which includes "boost/bind.hpp" you pollute the namespace. If you also use Boost.Lambda, you must change _1 to boost::lambda::_1.
Is this going to be fixed? Any workarounds?
This issue crops up since years and annoys everybody. I still pray for the day when someone removes this from :: I ended up using explicit namespace prefixes everywhere. Workaround: namespace bl = boost::lambda; // use bl::_1 in code Markus
Markus Werle a écrit :
This issue crops up since years and annoys everybody. I still pray for the day when someone removes this from :: Is there any specificities between all the various _,_1,_2 etc object ? Can't we build a small boost::placeholder and have all those libraries use them ?
-- ___________________________________________ Joel Falcou - Assistant Professor PARALL Team - LRI - Universite Paris Sud XI Tel : (+33)1 69 15 66 35
Joel Falcou <joel.falcou <at> u-psud.fr> writes:
Markus Werle a écrit :
This issue crops up since years and annoys everybody. I still pray for the day when someone removes this from :: Is there any specificities between all the various _,_1,_2 etc object ? Can't we build a small boost::placeholder and have all those libraries use them ?
Probably ... The problem is *not* the existence of 5 different versions of _1 inside boost. The problem is that one of those is in the wrong namespace and wins all the time even when it should not. Markus
This issue crops up since years and annoys everybody. I still pray for the day when someone removes this from ::
I ended up using explicit namespace prefixes everywhere.
Workaround:
namespace bl = boost::lambda; // use bl::_1 in code
Thanks; this thread.hpp annoyance is new... It was not present with 1.35, it must have begun either in 1.36 or 1.37.
participants (3)
-
anony
-
Joel Falcou
-
Markus Werle