boost 1.53的lambda中无法调用大于4的placeholder
我在vs2008环境使用boost 1.53的lambda库。
我遇到一个问题:
在使用boost::lambda时,编译器找不到_4、_5、_6、_7、_8、_9,即在lambda命名空间内只能找到编号不大于3的placeholder。而boost::bind库却可以使用9个placeholder。
我试过清空重新编译、建立其他工程编译,都不行。
假设函数fun5接受5个int的参数。
如果写:
using namespace boost::lambda;
function<int(int,int,int,int,int)> f=bind(fun5,999,_1,_2,_3,_4);
using namespace boost;
function<int(int,int,int,int,int)> f=bind(fun5,999,lambda::_1,lambda::_2,lambda::_3,lambda::_4);