------- Comment #13 from again at gmx dot de 2006-10-30 17:12 ------- (In reply to comment #11) > I believe the testcase is invalid.
You're right, therefore I'm closing this bug. The author of the Boost.Lambda library, Jaakko Järvi, kindly pointed my to a section of the library documentation, where it is written that arguments to lambda functions can't be non-const rvalues[1]. The following patch corrects the test case: --- test2.cpp.~1~ 2006-10-27 11:02:14.000000000 +0200 +++ test2.cpp 2006-10-30 18:05:06.000000000 +0100 @@ -11,6 +11,8 @@ int main() { int a = 1, b = 2; - std::cout << (boost::lambda::_1)(std::make_pair(a, b)) << std::endl; + std::cout + << (boost::lambda::_1)(boost::lambda::make_const(std::make_pair(a, b))) + << std::endl; return 0; } I don't know why it compiles cleanly on VC++, though. Best regards Christian [1] http://www.boost.org/doc/html/lambda/using_library.html#lambda.actual_arguments_to_lambda_functors -- again at gmx dot de changed: What |Removed |Added ---------------------------------------------------------------------------- Status|UNCONFIRMED |RESOLVED Resolution| |INVALID http://gcc.gnu.org/bugzilla/show_bug.cgi?id=29596