Boost Testing :
Subject: Re: [Boost-testing] A question on lambda under Dev-C++.Can anyone with kindness help me?
From: Steven Watanabe (watanabesj_at_[hidden])
Date: 2009-06-27 00:32:59
> By using Dev-C++ 22.214.171.124,I used boost::lambda£¬and the program contains the following lines£º
> typedef std::pair <int, int> mypair;
> but the complier told me that£º
> parse error before `,' token
> but when I use
> mypair£¨1£¬6£©£»instead of bind(&mypair,1,6); then everything is ok.
> Can anyone with kindness tell me why and how to solve it by using the function bind ?
mypair is a type, not a function so you can't take its address.
Use boost::lambda::constructor. http://tinyurl.com/ogjs8n.
bind(constructor<mypair>(), 1, 6);
P.S. In the future, please ask such questions on the boost-users list.