niedz., 28 mar 2021 o 21:26 Emil Dotchevski via Boost
On Sun, Mar 28, 2021 at 10:50 AM Barry Revzin via Boost < boost@lists.boost.org> wrote:
Second, this library has name lookup issues. Here's a reduced example ( https://godbolt.org/z/z8oEqnTnG):
#include <
https://raw.githubusercontent.com/pdimov/lambda2/develop/include/boost/lambd...
namespace N { struct Irrelevant { }; void operator+(Irrelevant, Irrelevant);
int plus_one(int i) { using namespace boost::lambda2; return (_1 + 1)(i); } }
To successfully compile, this has to be:
int plus_one(int i) { using namespace std::placeholders; using boost::lambda2::operator+; return (_1 + 1)(i); }
Note that it will not work if you say "using namespace boost::lambda2", you have to bring in each individual operator you need.
But is this how we recommend the library should be used? Regards, &rzej;
_______________________________________________ Unsubscribe & other changes: http://lists.boost.org/mailman/listinfo.cgi/boost