diff --git a/ndnboost/lambda/detail/actions.hpp b/ndnboost/lambda/detail/actions.hpp
new file mode 100644
index 0000000..8892bb1
--- /dev/null
+++ b/ndnboost/lambda/detail/actions.hpp
@@ -0,0 +1,174 @@
+// -- Boost Lambda Library - actions.hpp ----------------------------------
+
+// Copyright (C) 1999, 2000 Jaakko Jarvi (jaakko.jarvi@cs.utu.fi)
+//
+// Distributed under the Boost Software License, Version 1.0. (See
+// accompanying file LICENSE_1_0.txt or copy at
+// http://www.boost.org/LICENSE_1_0.txt)
+
+// For more information, see www.boost.org
+
+// ----------------------------------------------------------------
+
+#ifndef BOOST_LAMBDA_ACTIONS_HPP
+#define BOOST_LAMBDA_ACTIONS_HPP
+
+namespace ndnboost { 
+namespace lambda {
+
+
+
+template<int Arity, class Act> class action;
+
+// these need to be defined here, since the corresponding lambda 
+// functions are members of lambda_functor classes
+
+class assignment_action {};
+class subscript_action {};
+
+template <class Action> class other_action;
+
+// action for specifying the explicit return type
+template <class RET> class explicit_return_type_action {};
+
+// action for preventing the expansion of a lambda expression
+struct protect_action {};
+
+  // must be defined here, comma is a special case
+struct comma_action {};
+
+
+  // actions, for which the existence of protect is checked in return type 
+  // deduction.
+
+template <class Action> struct is_protectable {
+  BOOST_STATIC_CONSTANT(bool, value = false);
+};
+
+// NOTE: comma action is protectable. Other protectable actions
+// are listed in operator_actions.hpp
+
+template<> struct is_protectable<other_action<comma_action> > {
+  BOOST_STATIC_CONSTANT(bool, value = true);
+};
+
+
+namespace detail {
+
+  // this type is used in return type deductions to signal that deduction 
+  // did not find a result. It does not necessarily mean an error, it commonly
+  // means that something else should be tried.
+  class unspecified {};
+}
+
+  // function action is a special case: bind functions can be called with 
+  // the return type specialized explicitly e.g. bind<int>(foo);
+  // If this call syntax is used, the return type is stored in the latter
+  // argument of function_action template. Otherwise the argument gets the type
+  // 'unspecified'.
+  // This argument is only relevant in the return type deduction code
+template <int I, class Result_type = detail::unspecified> 
+class function_action {};
+   
+template<class T> class function_action<1, T> {
+public:
+  template<class RET, class A1>
+  static RET apply(A1& a1) {
+    return function_adaptor<typename ndnboost::remove_cv<A1>::type>::
+      template apply<RET>(a1);
+  }
+};
+
+template<class T> class function_action<2, T> {
+public:
+  template<class RET, class A1, class A2>
+  static RET apply(A1& a1, A2& a2) {
+    return function_adaptor<typename ndnboost::remove_cv<A1>::type>::
+      template apply<RET>(a1, a2);
+  }
+};
+
+template<class T> class function_action<3, T> {
+public:
+  template<class RET, class A1, class A2, class A3>
+  static RET apply(A1& a1, A2& a2, A3& a3) {
+    return function_adaptor<typename ndnboost::remove_cv<A1>::type>::
+      template apply<RET>(a1, a2, a3);
+  }
+};
+
+template<class T> class function_action<4, T> {
+public:
+  template<class RET, class A1, class A2, class A3, class A4>
+  static RET apply(A1& a1, A2& a2, A3& a3, A4& a4) {
+    return function_adaptor<typename ndnboost::remove_cv<A1>::type>::
+      template apply<RET>(a1, a2, a3, a4);
+  }
+};
+
+template<class T> class function_action<5, T> {
+public:
+  template<class RET, class A1, class A2, class A3, class A4, class A5>
+  static RET apply(A1& a1, A2& a2, A3& a3, A4& a4, A5& a5) {
+    return function_adaptor<typename ndnboost::remove_cv<A1>::type>::
+      template apply<RET>(a1, a2, a3, a4, a5);
+  }
+};
+
+template<class T> class function_action<6, T> {
+public:
+  template<class RET, class A1, class A2, class A3, class A4, class A5, 
+           class A6>
+  static RET apply(A1& a1, A2& a2, A3& a3, A4& a4, A5& a5, A6& a6) {
+    return function_adaptor<typename ndnboost::remove_cv<A1>::type>::
+      template apply<RET>(a1, a2, a3, a4, a5, a6);
+  }
+};
+
+template<class T> class function_action<7, T> {
+public:
+  template<class RET, class A1, class A2, class A3, class A4, class A5,  
+           class A6, class A7>
+  static RET apply(A1& a1, A2& a2, A3& a3, A4& a4, A5& a5, A6& a6, A7& a7) {
+    return function_adaptor<typename ndnboost::remove_cv<A1>::type>::
+      template apply<RET>(a1, a2, a3, a4, a5, a6, a7);
+  }
+};
+
+template<class T> class function_action<8, T> {
+public:
+  template<class RET, class A1, class A2, class A3, class A4, class A5, 
+           class A6, class A7, class A8>
+  static RET apply(A1& a1, A2& a2, A3& a3, A4& a4, A5& a5, A6& a6, A7& a7, 
+                   A8& a8) {
+    return function_adaptor<typename ndnboost::remove_cv<A1>::type>::
+      template apply<RET>(a1, a2, a3, a4, a5, a6, a7, a8);
+  }
+};
+
+template<class T> class function_action<9, T> {
+public:
+  template<class RET, class A1, class A2, class A3, class A4, class A5, 
+           class A6, class A7, class A8, class A9>
+  static RET apply(A1& a1, A2& a2, A3& a3, A4& a4, A5& a5, A6& a6, A7& a7, 
+                   A8& a8, A9& a9) {
+    return function_adaptor<typename ndnboost::remove_cv<A1>::type>::
+      template apply<RET>(a1, a2, a3, a4, a5, a6, a7, a8, a9);
+  }
+};
+
+template<class T> class function_action<10, T> {
+public:
+  template<class RET, class A1, class A2, class A3, class A4, class A5, 
+           class A6, class A7, class A8, class A9, class A10>
+  static RET apply(A1& a1, A2& a2, A3& a3, A4& a4, A5& a5, A6& a6, A7& a7, 
+                   A8& a8, A9& a9, A10& a10) {
+    return function_adaptor<typename ndnboost::remove_cv<A1>::type>::
+      template apply<RET>(a1, a2, a3, a4, a5, a6, a7, a8, a9, a10);
+  }
+};
+
+} // namespace lambda
+} // namespace ndnboost
+
+#endif
diff --git a/ndnboost/lambda/detail/arity_code.hpp b/ndnboost/lambda/detail/arity_code.hpp
new file mode 100644
index 0000000..2b762c3
--- /dev/null
+++ b/ndnboost/lambda/detail/arity_code.hpp
@@ -0,0 +1,110 @@
+// -- Boost Lambda Library -------------------------------------------------
+
+// Copyright (C) 1999, 2000 Jaakko Jarvi (jaakko.jarvi@cs.utu.fi)
+//
+// Distributed under the Boost Software License, Version 1.0. (See
+// accompanying file LICENSE_1_0.txt or copy at
+// http://www.boost.org/LICENSE_1_0.txt)
+//
+// For more information, see www.boost.org
+
+// --------------------------------------------------
+
+#ifndef BOOST_LAMBDA_ARITY_CODE_HPP
+#define BOOST_LAMBDA_ARITY_CODE_HPP
+
+#include "ndnboost/type_traits/cv_traits.hpp"
+#include "ndnboost/type_traits/transform_traits.hpp"
+
+namespace ndnboost { 
+namespace lambda {
+
+// These constants state, whether a lambda_functor instantiation results from 
+// an expression which contains no placeholders (NONE), 
+// only free1 placeholders (FIRST), 
+// free2 placeholders and maybe free1 placeholders (SECOND),
+// free3 and maybe free1 and free2 placeholders (THIRD),
+// freeE placeholders and maybe free1 and free2  (EXCEPTION).
+// RETHROW means, that a rethrow expression is used somewhere in the lambda_functor.
+
+enum { NONE             = 0x00, // Notice we are using bits as flags here.
+       FIRST            = 0x01, 
+       SECOND           = 0x02, 
+       THIRD            = 0x04, 
+       EXCEPTION        = 0x08, 
+       RETHROW          = 0x10};
+
+
+template<class T>
+struct get_tuple_arity;
+
+namespace detail {
+
+template <class T> struct get_arity_;
+
+} // end detail;
+
+template <class T> struct get_arity {
+
+  BOOST_STATIC_CONSTANT(int, value = detail::get_arity_<typename ndnboost::remove_cv<typename ndnboost::remove_reference<T>::type>::type>::value);
+
+};
+
+namespace detail {
+
+template<class T>
+struct get_arity_ {
+  BOOST_STATIC_CONSTANT(int, value = 0);
+};
+
+template<class T>
+struct get_arity_<lambda_functor<T> > {
+  BOOST_STATIC_CONSTANT(int, value = get_arity<T>::value);
+};
+
+template<class Action, class Args>
+struct get_arity_<lambda_functor_base<Action, Args> > {
+  BOOST_STATIC_CONSTANT(int, value = get_tuple_arity<Args>::value);
+};
+
+template<int I>
+struct get_arity_<placeholder<I> > {
+  BOOST_STATIC_CONSTANT(int, value = I);
+};
+
+} // detail 
+
+template<class T>
+struct get_tuple_arity {
+  BOOST_STATIC_CONSTANT(int, value = get_arity<typename T::head_type>::value | get_tuple_arity<typename T::tail_type>::value);
+};
+
+
+template<>
+struct get_tuple_arity<null_type> {
+  BOOST_STATIC_CONSTANT(int, value = 0);
+};
+
+
+  // Does T have placeholder<I> as it's subexpression?
+
+template<class T, int I>
+struct has_placeholder {
+  BOOST_STATIC_CONSTANT(bool, value = (get_arity<T>::value & I) != 0);
+}; 
+
+template<int I, int J>
+struct includes_placeholder {
+  BOOST_STATIC_CONSTANT(bool, value = (J & I) != 0);
+};
+
+template<int I, int J>
+struct lacks_placeholder {
+  BOOST_STATIC_CONSTANT(bool, value = ((J & I) == 0));
+};
+
+
+} // namespace lambda
+} // namespace ndnboost
+
+#endif
diff --git a/ndnboost/lambda/detail/bind_functions.hpp b/ndnboost/lambda/detail/bind_functions.hpp
new file mode 100644
index 0000000..4288067
--- /dev/null
+++ b/ndnboost/lambda/detail/bind_functions.hpp
@@ -0,0 +1,1879 @@
+// -- bind_functions.hpp -- Boost Lambda Library
+//
+// Copyright (C) 1999, 2000 Jaakko Jarvi (jaakko.jarvi@cs.utu.fi)
+//
+// Distributed under the Boost Software License, Version 1.0. (See
+// accompanying file LICENSE_1_0.txt or copy at
+// http://www.boost.org/LICENSE_1_0.txt)
+//
+// For more information, see http://www.boost.org
+
+// ----------------------------------------------------------------
+
+#ifndef BOOST_LAMBDA_BIND_FUNCTIONS_HPP
+#define BOOST_LAMBDA_BIND_FUNCTIONS_HPP
+
+
+namespace ndnboost { 
+namespace lambda {
+
+#ifdef BOOST_LAMBDA_INCORRECT_BIND_OVERLOADING
+
+  // gcc 2.96 instantiates bind functions it does not even call.
+  // These instantiations lead to incorrect types in the return type, 
+  // and a compilation error results. 
+  // This tweaking is to prevent the formation of the erroneous type.
+namespace detail {
+
+template<class T> struct constify_non_funcs {
+  typedef typename 
+  detail::IF_type<ndnboost::is_function<T>::value,
+    ndnboost::add_reference<T>,
+    ndnboost::add_const<T>
+  >::type type;
+};
+
+}
+#endif
+// 1-argument bind functions --------------------------
+#ifndef BOOST_REF_TO_FUNC_CONFLICTS_WITH_REF_TO_T
+template <class Result>
+inline const
+lambda_functor<
+  lambda_functor_base<
+    action<1, function_action<1, Result> >,
+    typename detail::bind_tuple_mapper<Result(&)()>::type
+  >
+>
+
+bind(Result(& a1)()) {
+  return
+    lambda_functor_base<
+      action<1, function_action<1, Result> >,
+      typename detail::bind_tuple_mapper<Result(&)()>::type
+    >
+    ( typename detail::bind_tuple_mapper<Result(&)()>::type
+      (a1)
+    );
+}
+#endif
+
+ #ifndef BOOST_LAMBDA_INCORRECT_BIND_OVERLOADING 
+template <class Arg1>
+inline const
+lambda_functor<
+  lambda_functor_base<
+    action<1, function_action<1> >,
+    typename detail::bind_tuple_mapper<const Arg1>::type
+  >
+>
+
+bind(const Arg1& a1) {
+  return
+    lambda_functor_base<
+      action<1, function_action<1> >,
+      typename detail::bind_tuple_mapper<const Arg1>::type
+    >
+    ( typename detail::bind_tuple_mapper<const Arg1>::type
+      (a1)
+    );
+}
+
+template <class Result, class Arg1>
+inline const
+lambda_functor<
+  lambda_functor_base<
+    action<1, function_action<1, Result> >,
+    typename detail::bind_tuple_mapper<const Arg1>::type
+  >
+>
+
+bind(const Arg1& a1) {
+  return
+    lambda_functor_base<
+      action<1, function_action<1, Result> >,
+      typename detail::bind_tuple_mapper<const Arg1>::type
+    >
+    ( typename detail::bind_tuple_mapper<const Arg1>::type
+      (a1)
+    );
+}
+
+
+ #else 
+template <class Arg1>
+inline const
+lambda_functor<
+  lambda_functor_base<
+    action<1, function_action<1> >,
+    typename detail::bind_tuple_mapper<
+      typename detail::constify_non_funcs<Arg1>::type
+    >::type
+  >
+>
+
+bind(const Arg1& a1) {
+  return
+    lambda_functor_base<
+      action<1, function_action<1> >,
+      typename detail::bind_tuple_mapper<
+        typename detail::constify_non_funcs<Arg1>::type
+      >::type
+    >
+    ( typename detail::bind_tuple_mapper<
+        typename detail::constify_non_funcs<Arg1>::type
+      >::type
+      (a1)
+    );
+}
+
+template <class Result, class Arg1>
+inline const
+lambda_functor<
+  lambda_functor_base<
+    action<1, function_action<1, Result> >,
+    typename detail::bind_tuple_mapper<
+      typename detail::constify_non_funcs<Arg1>::type
+    >::type
+  >
+>
+
+bind(const Arg1& a1) {
+  return
+    lambda_functor_base<
+      action<1, function_action<1, Result> >,
+      typename detail::bind_tuple_mapper<
+        typename detail::constify_non_funcs<Arg1>::type
+      >::type
+    >
+    ( typename detail::bind_tuple_mapper<
+        typename detail::constify_non_funcs<Arg1>::type
+      >::type
+      (a1)
+    );
+}
+
+template <class Result>
+inline const
+lambda_functor<
+  lambda_functor_base<
+    action<1, function_action<1, Result> >,
+    typename detail::bind_tuple_mapper<Result(*)()>::type
+  >
+>
+
+bind(Result(* const & a1)()) {
+  return
+    lambda_functor_base<
+      action<1, function_action<1, Result> >,
+      typename detail::bind_tuple_mapper<Result(*)()>::type
+    >
+    ( typename detail::bind_tuple_mapper<Result(*)()>::type
+      (a1)
+    );
+}
+
+
+#endif 
+
+// 2-argument bind functions --------------------------
+#ifndef BOOST_REF_TO_FUNC_CONFLICTS_WITH_REF_TO_T
+template <class Result, class Par1, class Arg2>
+inline const
+lambda_functor<
+  lambda_functor_base<
+    action<2, function_action<2, Result> >,
+    typename detail::bind_tuple_mapper<Result(&)(Par1), const Arg2>::type
+  >
+>
+
+bind(Result(&a1)(Par1), const Arg2& a2) {
+  return
+    lambda_functor_base<
+      action<2, function_action<2, Result> >,
+      typename detail::bind_tuple_mapper<Result(&)(Par1), const Arg2>::type
+    >
+    ( typename detail::bind_tuple_mapper<Result(&)(Par1), const Arg2>::type
+      (a1, a2)
+    );
+}
+#endif
+
+#ifndef BOOST_LAMBDA_INCORRECT_BIND_OVERLOADING 
+template <class Arg1, class Arg2>
+inline const
+lambda_functor<
+  lambda_functor_base<
+    action<2, function_action<2> >,
+    typename detail::bind_tuple_mapper<const Arg1, const Arg2>::type
+  >
+>
+
+bind(const Arg1& a1, const Arg2& a2) {
+  return
+    lambda_functor_base<
+      action<2, function_action<2> >,
+      typename detail::bind_tuple_mapper<const Arg1, const Arg2>::type
+    >
+    ( typename detail::bind_tuple_mapper<const Arg1, const Arg2>::type
+      (a1, a2)
+    );
+}
+
+template <class Result, class Arg1, class Arg2>
+inline const
+lambda_functor<
+  lambda_functor_base<
+    action<2, function_action<2, Result> >,
+    typename detail::bind_tuple_mapper<const Arg1, const Arg2>::type
+  >
+>
+
+bind(const Arg1& a1, const Arg2& a2) {
+  return
+    lambda_functor_base<
+      action<2, function_action<2, Result> >,
+      typename detail::bind_tuple_mapper<const Arg1, const Arg2>::type
+    >
+    ( typename detail::bind_tuple_mapper<const Arg1, const Arg2>::type
+      (a1, a2)
+    );
+}
+
+
+ #else 
+template <class Arg1, class Arg2>
+inline const
+lambda_functor<
+  lambda_functor_base<
+    action<2, function_action<2> >,
+    typename detail::bind_tuple_mapper<
+      typename detail::constify_non_funcs<Arg1>::type, const Arg2
+    >::type
+  >
+>
+
+bind(const Arg1& a1, const Arg2& a2) {
+  return
+    lambda_functor_base<
+      action<2, function_action<2> >,
+      typename detail::bind_tuple_mapper<
+        typename detail::constify_non_funcs<Arg1>::type, const Arg2
+      >::type
+    >
+    ( typename detail::bind_tuple_mapper<
+        typename detail::constify_non_funcs<Arg1>::type, const Arg2
+      >::type
+      (a1, a2)
+    );
+}
+
+template <class Result, class Arg1, class Arg2>
+inline const
+lambda_functor<
+  lambda_functor_base<
+    action<2, function_action<2, Result> >,
+    typename detail::bind_tuple_mapper<
+      typename detail::constify_non_funcs<Arg1>::type, const Arg2
+    >::type
+  >
+>
+
+bind(const Arg1& a1, const Arg2& a2) {
+  return
+    lambda_functor_base<
+      action<2, function_action<2, Result> >,
+      typename detail::bind_tuple_mapper<
+        typename detail::constify_non_funcs<Arg1>::type, const Arg2
+      >::type
+    >
+    ( typename detail::bind_tuple_mapper<
+        typename detail::constify_non_funcs<Arg1>::type, const Arg2
+      >::type
+      (a1, a2)
+    );
+}
+
+template <class Result, class Par1, class Arg2>
+inline const
+lambda_functor<
+  lambda_functor_base<
+    action<2, function_action<2, Result> >,
+    typename detail::bind_tuple_mapper<Result(*)(Par1), const Arg2>::type
+  >
+>
+
+bind(Result(* const & a1)(Par1), const Arg2& a2) {
+  return
+    lambda_functor_base<
+      action<2, function_action<2, Result> >,
+      typename detail::bind_tuple_mapper<Result(*)(Par1), const Arg2>::type
+    >
+    ( typename detail::bind_tuple_mapper<Result(*)(Par1), const Arg2>::type
+      (a1, a2)
+    );
+}
+
+
+ #endif 
+
+// 3-argument bind functions --------------------------
+#ifndef BOOST_REF_TO_FUNC_CONFLICTS_WITH_REF_TO_T
+template <class Result, class Par1, class Par2, class Arg2, class Arg3>
+inline const
+lambda_functor<
+  lambda_functor_base<
+    action<3, function_action<3, Result> >,
+    typename detail::bind_tuple_mapper<
+      Result(&)(Par1, Par2), const Arg2, const Arg3
+    >::type
+  >
+>
+
+bind(Result(&a1)(Par1, Par2), const Arg2& a2, const Arg3& a3) {
+  return
+    lambda_functor_base<
+      action<3, function_action<3, Result> >,
+      typename detail::bind_tuple_mapper<
+        Result(&)(Par1, Par2), const Arg2, const Arg3
+      >::type
+    >
+    ( typename detail::bind_tuple_mapper<
+        Result(&)(Par1, Par2), const Arg2, const Arg3
+      >::type
+      (a1, a2, a3)
+    );
+}
+#endif
+
+ #ifndef BOOST_LAMBDA_INCORRECT_BIND_OVERLOADING 
+template <class Arg1, class Arg2, class Arg3>
+inline const
+lambda_functor<
+  lambda_functor_base<
+    action<3, function_action<3> >,
+    typename detail::bind_tuple_mapper<
+      const Arg1, const Arg2, const Arg3
+    >::type
+  >
+>
+
+bind(const Arg1& a1, const Arg2& a2, const Arg3& a3) {
+  return
+    lambda_functor_base<
+      action<3, function_action<3> >,
+      typename detail::bind_tuple_mapper<
+        const Arg1, const Arg2, const Arg3
+      >::type
+    >
+    ( typename detail::bind_tuple_mapper<
+        const Arg1, const Arg2, const Arg3
+      >::type
+      (a1, a2, a3)
+    );
+}
+
+template <class Result, class Arg1, class Arg2, class Arg3>
+inline const
+lambda_functor<
+  lambda_functor_base<
+    action<3, function_action<3, Result> >,
+    typename detail::bind_tuple_mapper<
+      const Arg1, const Arg2, const Arg3
+    >::type
+  >
+>
+
+bind(const Arg1& a1, const Arg2& a2, const Arg3& a3) {
+  return
+    lambda_functor_base<
+      action<3, function_action<3, Result> >,
+      typename detail::bind_tuple_mapper<
+        const Arg1, const Arg2, const Arg3
+      >::type
+    >
+    ( typename detail::bind_tuple_mapper<
+        const Arg1, const Arg2, const Arg3
+      >::type
+      (a1, a2, a3)
+    );
+}
+
+
+ #else 
+template <class Arg1, class Arg2, class Arg3>
+inline const
+lambda_functor<
+  lambda_functor_base<
+    action<3, function_action<3> >,
+    typename detail::bind_tuple_mapper<
+      typename detail::constify_non_funcs<Arg1>::type, const Arg2, const Arg3
+    >::type
+  >
+>
+
+bind(const Arg1& a1, const Arg2& a2, const Arg3& a3) {
+  return
+    lambda_functor_base<
+      action<3, function_action<3> >,
+      typename detail::bind_tuple_mapper<
+        typename detail::constify_non_funcs<Arg1>::type, const Arg2,
+        const Arg3
+      >::type
+    >
+    ( typename detail::bind_tuple_mapper<
+        typename detail::constify_non_funcs<Arg1>::type, const Arg2,
+        const Arg3
+      >::type
+      (a1, a2, a3)
+    );
+}
+
+template <class Result, class Arg1, class Arg2, class Arg3>
+inline const
+lambda_functor<
+  lambda_functor_base<
+    action<3, function_action<3, Result> >,
+    typename detail::bind_tuple_mapper<
+      typename detail::constify_non_funcs<Arg1>::type, const Arg2, const Arg3
+    >::type
+  >
+>
+
+bind(const Arg1& a1, const Arg2& a2, const Arg3& a3) {
+  return
+    lambda_functor_base<
+      action<3, function_action<3, Result> >,
+      typename detail::bind_tuple_mapper<
+        typename detail::constify_non_funcs<Arg1>::type, const Arg2,
+        const Arg3
+      >::type
+    >
+    ( typename detail::bind_tuple_mapper<
+        typename detail::constify_non_funcs<Arg1>::type, const Arg2,
+        const Arg3
+      >::type
+      (a1, a2, a3)
+    );
+}
+
+template <class Result, class Par1, class Par2, class Arg2, class Arg3>
+inline const
+lambda_functor<
+  lambda_functor_base<
+    action<3, function_action<3, Result> >,
+    typename detail::bind_tuple_mapper<
+      Result(*)(Par1, Par2), const Arg2, const Arg3
+    >::type
+  >
+>
+
+bind(Result(* const & a1)(Par1, Par2), const Arg2& a2, const Arg3& a3) {
+  return
+    lambda_functor_base<
+      action<3, function_action<3, Result> >,
+      typename detail::bind_tuple_mapper<
+        Result(*)(Par1, Par2), const Arg2, const Arg3
+      >::type
+    >
+    ( typename detail::bind_tuple_mapper<
+        Result(*)(Par1, Par2), const Arg2, const Arg3
+      >::type
+      (a1, a2, a3)
+    );
+}
+
+
+ #endif 
+
+// 4-argument bind functions --------------------------
+#ifndef BOOST_REF_TO_FUNC_CONFLICTS_WITH_REF_TO_T
+template <class Result, class Par1, class Par2, class Par3, class Arg2,
+          class Arg3, class Arg4>
+inline const
+lambda_functor<
+  lambda_functor_base<
+    action<4, function_action<4, Result> >,
+    typename detail::bind_tuple_mapper<
+      Result(&)(Par1, Par2, Par3), const Arg2, const Arg3, const Arg4
+    >::type
+  >
+>
+
+bind(Result(&a1)(Par1, Par2, Par3), const Arg2& a2, const Arg3& a3,
+     const Arg4& a4) {
+  return
+    lambda_functor_base<
+      action<4, function_action<4, Result> >,
+      typename detail::bind_tuple_mapper<
+        Result(&)(Par1, Par2, Par3), const Arg2, const Arg3, const Arg4
+      >::type
+    >
+    ( typename detail::bind_tuple_mapper<
+        Result(&)(Par1, Par2, Par3), const Arg2, const Arg3, const Arg4
+      >::type
+      (a1, a2, a3, a4)
+    );
+}
+#endif
+
+ #ifndef BOOST_LAMBDA_INCORRECT_BIND_OVERLOADING 
+template <class Arg1, class Arg2, class Arg3, class Arg4>
+inline const
+lambda_functor<
+  lambda_functor_base<
+    action<4, function_action<4> >,
+    typename detail::bind_tuple_mapper<
+      const Arg1, const Arg2, const Arg3, const Arg4
+    >::type
+  >
+>
+
+bind(const Arg1& a1, const Arg2& a2, const Arg3& a3, const Arg4& a4) {
+  return
+    lambda_functor_base<
+      action<4, function_action<4> >,
+      typename detail::bind_tuple_mapper<
+        const Arg1, const Arg2, const Arg3, const Arg4
+      >::type
+    >
+    ( typename detail::bind_tuple_mapper<
+        const Arg1, const Arg2, const Arg3, const Arg4
+      >::type
+      (a1, a2, a3, a4)
+    );
+}
+
+template <class Result, class Arg1, class Arg2, class Arg3, class Arg4>
+inline const
+lambda_functor<
+  lambda_functor_base<
+    action<4, function_action<4, Result> >,
+    typename detail::bind_tuple_mapper<
+      const Arg1, const Arg2, const Arg3, const Arg4
+    >::type
+  >
+>
+
+bind(const Arg1& a1, const Arg2& a2, const Arg3& a3, const Arg4& a4) {
+  return
+    lambda_functor_base<
+      action<4, function_action<4, Result> >,
+      typename detail::bind_tuple_mapper<
+        const Arg1, const Arg2, const Arg3, const Arg4
+      >::type
+    >
+    ( typename detail::bind_tuple_mapper<
+        const Arg1, const Arg2, const Arg3, const Arg4
+      >::type
+      (a1, a2, a3, a4)
+    );
+}
+
+
+ #else 
+template <class Arg1, class Arg2, class Arg3, class Arg4>
+inline const
+lambda_functor<
+  lambda_functor_base<
+    action<4, function_action<4> >,
+    typename detail::bind_tuple_mapper<
+      typename detail::constify_non_funcs<Arg1>::type, const Arg2, const Arg3,
+      const Arg4
+    >::type
+  >
+>
+
+bind(const Arg1& a1, const Arg2& a2, const Arg3& a3, const Arg4& a4) {
+  return
+    lambda_functor_base<
+      action<4, function_action<4> >,
+      typename detail::bind_tuple_mapper<
+        typename detail::constify_non_funcs<Arg1>::type, const Arg2,
+        const Arg3, const Arg4
+      >::type
+    >
+    ( typename detail::bind_tuple_mapper<
+        typename detail::constify_non_funcs<Arg1>::type, const Arg2,
+        const Arg3, const Arg4
+      >::type
+      (a1, a2, a3, a4)
+    );
+}
+
+template <class Result, class Arg1, class Arg2, class Arg3, class Arg4>
+inline const
+lambda_functor<
+  lambda_functor_base<
+    action<4, function_action<4, Result> >,
+    typename detail::bind_tuple_mapper<
+      typename detail::constify_non_funcs<Arg1>::type, const Arg2, const Arg3,
+      const Arg4
+    >::type
+  >
+>
+
+bind(const Arg1& a1, const Arg2& a2, const Arg3& a3, const Arg4& a4) {
+  return
+    lambda_functor_base<
+      action<4, function_action<4, Result> >,
+      typename detail::bind_tuple_mapper<
+        typename detail::constify_non_funcs<Arg1>::type, const Arg2,
+        const Arg3, const Arg4
+      >::type
+    >
+    ( typename detail::bind_tuple_mapper<
+        typename detail::constify_non_funcs<Arg1>::type, const Arg2,
+        const Arg3, const Arg4
+      >::type
+      (a1, a2, a3, a4)
+    );
+}
+
+template <class Result, class Par1, class Par2, class Par3, class Arg2,
+          class Arg3, class Arg4>
+inline const
+lambda_functor<
+  lambda_functor_base<
+    action<4, function_action<4, Result> >,
+    typename detail::bind_tuple_mapper<
+      Result(*)(Par1, Par2, Par3), const Arg2, const Arg3, const Arg4
+    >::type
+  >
+>
+
+bind(Result(* const & a1)(Par1, Par2, Par3), const Arg2& a2,
+     const Arg3& a3, const Arg4& a4) {
+  return
+    lambda_functor_base<
+      action<4, function_action<4, Result> >,
+      typename detail::bind_tuple_mapper<
+        Result(*)(Par1, Par2, Par3), const Arg2, const Arg3, const Arg4
+      >::type
+    >
+    ( typename detail::bind_tuple_mapper<
+        Result(*)(Par1, Par2, Par3), const Arg2, const Arg3, const Arg4
+      >::type
+      (a1, a2, a3, a4)
+    );
+}
+
+
+ #endif 
+
+// 5-argument bind functions --------------------------
+#ifndef BOOST_REF_TO_FUNC_CONFLICTS_WITH_REF_TO_T
+template <class Result, class Par1, class Par2, class Par3, class Par4,
+          class Arg2, class Arg3, class Arg4, class Arg5>
+inline const
+lambda_functor<
+  lambda_functor_base<
+    action<5, function_action<5, Result> >,
+    typename detail::bind_tuple_mapper<
+      Result(&)(Par1, Par2, Par3, Par4), const Arg2, const Arg3, const Arg4,
+      const Arg5
+    >::type
+  >
+>
+
+bind(Result(&a1)(Par1, Par2, Par3, Par4), const Arg2& a2, const Arg3& a3,
+     const Arg4& a4, const Arg5& a5) {
+  return
+    lambda_functor_base<
+      action<5, function_action<5, Result> >,
+      typename detail::bind_tuple_mapper<
+        Result(&)(Par1, Par2, Par3, Par4), const Arg2, const Arg3, const Arg4,
+        const Arg5
+      >::type
+    >
+    ( typename detail::bind_tuple_mapper<
+        Result(&)(Par1, Par2, Par3, Par4), const Arg2, const Arg3, const Arg4,
+        const Arg5
+      >::type
+      (a1, a2, a3, a4, a5)
+    );
+}
+#endif
+
+ #ifndef BOOST_LAMBDA_INCORRECT_BIND_OVERLOADING 
+template <class Arg1, class Arg2, class Arg3, class Arg4, class Arg5>
+inline const
+lambda_functor<
+  lambda_functor_base<
+    action<5, function_action<5> >,
+    typename detail::bind_tuple_mapper<
+      const Arg1, const Arg2, const Arg3, const Arg4, const Arg5
+    >::type
+  >
+>
+
+bind(const Arg1& a1, const Arg2& a2, const Arg3& a3, const Arg4& a4,
+     const Arg5& a5) {
+  return
+    lambda_functor_base<
+      action<5, function_action<5> >,
+      typename detail::bind_tuple_mapper<
+        const Arg1, const Arg2, const Arg3, const Arg4, const Arg5
+      >::type
+    >
+    ( typename detail::bind_tuple_mapper<
+        const Arg1, const Arg2, const Arg3, const Arg4, const Arg5
+      >::type
+      (a1, a2, a3, a4, a5)
+    );
+}
+
+template <class Result, class Arg1, class Arg2, class Arg3, class Arg4,
+          class Arg5>
+inline const
+lambda_functor<
+  lambda_functor_base<
+    action<5, function_action<5, Result> >,
+    typename detail::bind_tuple_mapper<
+      const Arg1, const Arg2, const Arg3, const Arg4, const Arg5
+    >::type
+  >
+>
+
+bind(const Arg1& a1, const Arg2& a2, const Arg3& a3, const Arg4& a4,
+     const Arg5& a5) {
+  return
+    lambda_functor_base<
+      action<5, function_action<5, Result> >,
+      typename detail::bind_tuple_mapper<
+        const Arg1, const Arg2, const Arg3, const Arg4, const Arg5
+      >::type
+    >
+    ( typename detail::bind_tuple_mapper<
+        const Arg1, const Arg2, const Arg3, const Arg4, const Arg5
+      >::type
+      (a1, a2, a3, a4, a5)
+    );
+}
+
+
+ #else 
+template <class Arg1, class Arg2, class Arg3, class Arg4, class Arg5>
+inline const
+lambda_functor<
+  lambda_functor_base<
+    action<5, function_action<5> >,
+    typename detail::bind_tuple_mapper<
+      typename detail::constify_non_funcs<Arg1>::type, const Arg2, const Arg3,
+      const Arg4, const Arg5
+    >::type
+  >
+>
+
+bind(const Arg1& a1, const Arg2& a2, const Arg3& a3, const Arg4& a4,
+     const Arg5& a5) {
+  return
+    lambda_functor_base<
+      action<5, function_action<5> >,
+      typename detail::bind_tuple_mapper<
+        typename detail::constify_non_funcs<Arg1>::type, const Arg2,
+        const Arg3, const Arg4, const Arg5
+      >::type
+    >
+    ( typename detail::bind_tuple_mapper<
+        typename detail::constify_non_funcs<Arg1>::type, const Arg2,
+        const Arg3, const Arg4, const Arg5
+      >::type
+      (a1, a2, a3, a4, a5)
+    );
+}
+
+template <class Result, class Arg1, class Arg2, class Arg3, class Arg4,
+          class Arg5>
+inline const
+lambda_functor<
+  lambda_functor_base<
+    action<5, function_action<5, Result> >,
+    typename detail::bind_tuple_mapper<
+      typename detail::constify_non_funcs<Arg1>::type, const Arg2, const Arg3,
+      const Arg4, const Arg5
+    >::type
+  >
+>
+
+bind(const Arg1& a1, const Arg2& a2, const Arg3& a3, const Arg4& a4,
+     const Arg5& a5) {
+  return
+    lambda_functor_base<
+      action<5, function_action<5, Result> >,
+      typename detail::bind_tuple_mapper<
+        typename detail::constify_non_funcs<Arg1>::type, const Arg2,
+        const Arg3, const Arg4, const Arg5
+      >::type
+    >
+    ( typename detail::bind_tuple_mapper<
+        typename detail::constify_non_funcs<Arg1>::type, const Arg2,
+        const Arg3, const Arg4, const Arg5
+      >::type
+      (a1, a2, a3, a4, a5)
+    );
+}
+
+template <class Result, class Par1, class Par2, class Par3, class Par4,
+          class Arg2, class Arg3, class Arg4, class Arg5>
+inline const
+lambda_functor<
+  lambda_functor_base<
+    action<5, function_action<5, Result> >,
+    typename detail::bind_tuple_mapper<
+      Result(*)(Par1, Par2, Par3, Par4), const Arg2, const Arg3, const Arg4,
+      const Arg5
+    >::type
+  >
+>
+
+bind(Result(* const & a1)(Par1, Par2, Par3, Par4), const Arg2& a2,
+     const Arg3& a3, const Arg4& a4, const Arg5& a5) {
+  return
+    lambda_functor_base<
+      action<5, function_action<5, Result> >,
+      typename detail::bind_tuple_mapper<
+        Result(*)(Par1, Par2, Par3, Par4), const Arg2, const Arg3, const Arg4,
+        const Arg5
+      >::type
+    >
+    ( typename detail::bind_tuple_mapper<
+        Result(*)(Par1, Par2, Par3, Par4), const Arg2, const Arg3, const Arg4,
+        const Arg5
+      >::type
+      (a1, a2, a3, a4, a5)
+    );
+}
+
+
+ #endif 
+
+// 6-argument bind functions --------------------------
+#ifndef BOOST_REF_TO_FUNC_CONFLICTS_WITH_REF_TO_T
+template <class Result, class Par1, class Par2, class Par3, class Par4,
+          class Par5, class Arg2, class Arg3, class Arg4, class Arg5,
+          class Arg6>
+inline const
+lambda_functor<
+  lambda_functor_base<
+    action<6, function_action<6, Result> >,
+    typename detail::bind_tuple_mapper<
+      Result(&)(Par1, Par2, Par3, Par4, Par5), const Arg2, const Arg3,
+      const Arg4, const Arg5, const Arg6
+    >::type
+  >
+>
+
+bind(Result(&a1)(Par1, Par2, Par3, Par4, Par5), const Arg2& a2,
+     const Arg3& a3, const Arg4& a4, const Arg5& a5, const Arg6& a6) {
+  return
+    lambda_functor_base<
+      action<6, function_action<6, Result> >,
+      typename detail::bind_tuple_mapper<
+        Result(&)(Par1, Par2, Par3, Par4, Par5), const Arg2, const Arg3,
+        const Arg4, const Arg5, const Arg6
+      >::type
+    >
+    ( typename detail::bind_tuple_mapper<
+        Result(&)(Par1, Par2, Par3, Par4, Par5), const Arg2, const Arg3,
+        const Arg4, const Arg5, const Arg6
+      >::type
+      (a1, a2, a3, a4, a5, a6)
+    );
+}
+#endif
+
+ #ifndef BOOST_LAMBDA_INCORRECT_BIND_OVERLOADING 
+template <class Arg1, class Arg2, class Arg3, class Arg4, class Arg5,
+          class Arg6>
+inline const
+lambda_functor<
+  lambda_functor_base<
+    action<6, function_action<6> >,
+    typename detail::bind_tuple_mapper<
+      const Arg1, const Arg2, const Arg3, const Arg4, const Arg5, const Arg6
+    >::type
+  >
+>
+
+bind(const Arg1& a1, const Arg2& a2, const Arg3& a3, const Arg4& a4,
+     const Arg5& a5, const Arg6& a6) {
+  return
+    lambda_functor_base<
+      action<6, function_action<6> >,
+      typename detail::bind_tuple_mapper<
+        const Arg1, const Arg2, const Arg3, const Arg4, const Arg5, const Arg6
+      >::type
+    >
+    ( typename detail::bind_tuple_mapper<
+        const Arg1, const Arg2, const Arg3, const Arg4, const Arg5, const Arg6
+      >::type
+      (a1, a2, a3, a4, a5, a6)
+    );
+}
+
+template <class Result, class Arg1, class Arg2, class Arg3, class Arg4,
+          class Arg5, class Arg6>
+inline const
+lambda_functor<
+  lambda_functor_base<
+    action<6, function_action<6, Result> >,
+    typename detail::bind_tuple_mapper<
+      const Arg1, const Arg2, const Arg3, const Arg4, const Arg5, const Arg6
+    >::type
+  >
+>
+
+bind(const Arg1& a1, const Arg2& a2, const Arg3& a3, const Arg4& a4,
+     const Arg5& a5, const Arg6& a6) {
+  return
+    lambda_functor_base<
+      action<6, function_action<6, Result> >,
+      typename detail::bind_tuple_mapper<
+        const Arg1, const Arg2, const Arg3, const Arg4, const Arg5, const Arg6
+      >::type
+    >
+    ( typename detail::bind_tuple_mapper<
+        const Arg1, const Arg2, const Arg3, const Arg4, const Arg5, const Arg6
+      >::type
+      (a1, a2, a3, a4, a5, a6)
+    );
+}
+
+
+ #else 
+template <class Arg1, class Arg2, class Arg3, class Arg4, class Arg5,
+          class Arg6>
+inline const
+lambda_functor<
+  lambda_functor_base<
+    action<6, function_action<6> >,
+    typename detail::bind_tuple_mapper<
+      typename detail::constify_non_funcs<Arg1>::type, const Arg2, const Arg3,
+      const Arg4, const Arg5, const Arg6
+    >::type
+  >
+>
+
+bind(const Arg1& a1, const Arg2& a2, const Arg3& a3, const Arg4& a4,
+     const Arg5& a5, const Arg6& a6) {
+  return
+    lambda_functor_base<
+      action<6, function_action<6> >,
+      typename detail::bind_tuple_mapper<
+        typename detail::constify_non_funcs<Arg1>::type, const Arg2,
+        const Arg3, const Arg4, const Arg5, const Arg6
+      >::type
+    >
+    ( typename detail::bind_tuple_mapper<
+        typename detail::constify_non_funcs<Arg1>::type, const Arg2,
+        const Arg3, const Arg4, const Arg5, const Arg6
+      >::type
+      (a1, a2, a3, a4, a5, a6)
+    );
+}
+
+template <class Result, class Arg1, class Arg2, class Arg3, class Arg4,
+          class Arg5, class Arg6>
+inline const
+lambda_functor<
+  lambda_functor_base<
+    action<6, function_action<6, Result> >,
+    typename detail::bind_tuple_mapper<
+      typename detail::constify_non_funcs<Arg1>::type, const Arg2, const Arg3,
+      const Arg4, const Arg5, const Arg6
+    >::type
+  >
+>
+
+bind(const Arg1& a1, const Arg2& a2, const Arg3& a3, const Arg4& a4,
+     const Arg5& a5, const Arg6& a6) {
+  return
+    lambda_functor_base<
+      action<6, function_action<6, Result> >,
+      typename detail::bind_tuple_mapper<
+        typename detail::constify_non_funcs<Arg1>::type, const Arg2,
+        const Arg3, const Arg4, const Arg5, const Arg6
+      >::type
+    >
+    ( typename detail::bind_tuple_mapper<
+        typename detail::constify_non_funcs<Arg1>::type, const Arg2,
+        const Arg3, const Arg4, const Arg5, const Arg6
+      >::type
+      (a1, a2, a3, a4, a5, a6)
+    );
+}
+
+template <class Result, class Par1, class Par2, class Par3, class Par4,
+          class Par5, class Arg2, class Arg3, class Arg4, class Arg5,
+          class Arg6>
+inline const
+lambda_functor<
+  lambda_functor_base<
+    action<6, function_action<6, Result> >,
+    typename detail::bind_tuple_mapper<
+      Result(*)(Par1, Par2, Par3, Par4, Par5), const Arg2, const Arg3,
+      const Arg4, const Arg5, const Arg6
+    >::type
+  >
+>
+
+bind(Result(* const & a1)(Par1, Par2, Par3, Par4, Par5), const Arg2& a2,
+     const Arg3& a3, const Arg4& a4, const Arg5& a5, const Arg6& a6) {
+  return
+    lambda_functor_base<
+      action<6, function_action<6, Result> >,
+      typename detail::bind_tuple_mapper<
+        Result(*)(Par1, Par2, Par3, Par4, Par5), const Arg2, const Arg3,
+        const Arg4, const Arg5, const Arg6
+      >::type
+    >
+    ( typename detail::bind_tuple_mapper<
+        Result(*)(Par1, Par2, Par3, Par4, Par5), const Arg2, const Arg3,
+        const Arg4, const Arg5, const Arg6
+      >::type
+      (a1, a2, a3, a4, a5, a6)
+    );
+}
+
+
+ #endif 
+
+// 7-argument bind functions --------------------------
+#ifndef BOOST_REF_TO_FUNC_CONFLICTS_WITH_REF_TO_T
+template <class Result, class Par1, class Par2, class Par3, class Par4,
+          class Par5, class Par6, class Arg2, class Arg3, class Arg4,
+          class Arg5, class Arg6, class Arg7>
+inline const
+lambda_functor<
+  lambda_functor_base<
+    action<7, function_action<7, Result> >,
+    typename detail::bind_tuple_mapper<
+      Result(&)(Par1, Par2, Par3, Par4, Par5, Par6), const Arg2, const Arg3,
+      const Arg4, const Arg5, const Arg6, const Arg7
+    >::type
+  >
+>
+
+bind(Result(&a1)(Par1, Par2, Par3, Par4, Par5, Par6), const Arg2& a2,
+     const Arg3& a3, const Arg4& a4, const Arg5& a5, const Arg6& a6,
+     const Arg7& a7) {
+  return
+    lambda_functor_base<
+      action<7, function_action<7, Result> >,
+      typename detail::bind_tuple_mapper<
+        Result(&)(Par1, Par2, Par3, Par4, Par5, Par6), const Arg2, const Arg3,
+        const Arg4, const Arg5, const Arg6, const Arg7
+      >::type
+    >
+    ( typename detail::bind_tuple_mapper<
+        Result(&)(Par1, Par2, Par3, Par4, Par5, Par6), const Arg2, const Arg3,
+        const Arg4, const Arg5, const Arg6, const Arg7
+      >::type
+      (a1, a2, a3, a4, a5, a6, a7)
+    );
+}
+#endif
+
+ #ifndef BOOST_LAMBDA_INCORRECT_BIND_OVERLOADING 
+template <class Arg1, class Arg2, class Arg3, class Arg4, class Arg5,
+          class Arg6, class Arg7>
+inline const
+lambda_functor<
+  lambda_functor_base<
+    action<7, function_action<7> >,
+    typename detail::bind_tuple_mapper<
+      const Arg1, const Arg2, const Arg3, const Arg4, const Arg5, const Arg6,
+      const Arg7
+    >::type
+  >
+>
+
+bind(const Arg1& a1, const Arg2& a2, const Arg3& a3, const Arg4& a4,
+     const Arg5& a5, const Arg6& a6, const Arg7& a7) {
+  return
+    lambda_functor_base<
+      action<7, function_action<7> >,
+      typename detail::bind_tuple_mapper<
+        const Arg1, const Arg2, const Arg3, const Arg4, const Arg5,
+        const Arg6, const Arg7
+      >::type
+    >
+    ( typename detail::bind_tuple_mapper<
+        const Arg1, const Arg2, const Arg3, const Arg4, const Arg5,
+        const Arg6, const Arg7
+      >::type
+      (a1, a2, a3, a4, a5, a6, a7)
+    );
+}
+
+template <class Result, class Arg1, class Arg2, class Arg3, class Arg4,
+          class Arg5, class Arg6, class Arg7>
+inline const
+lambda_functor<
+  lambda_functor_base<
+    action<7, function_action<7, Result> >,
+    typename detail::bind_tuple_mapper<
+      const Arg1, const Arg2, const Arg3, const Arg4, const Arg5, const Arg6,
+      const Arg7
+    >::type
+  >
+>
+
+bind(const Arg1& a1, const Arg2& a2, const Arg3& a3, const Arg4& a4,
+     const Arg5& a5, const Arg6& a6, const Arg7& a7) {
+  return
+    lambda_functor_base<
+      action<7, function_action<7, Result> >,
+      typename detail::bind_tuple_mapper<
+        const Arg1, const Arg2, const Arg3, const Arg4, const Arg5,
+        const Arg6, const Arg7
+      >::type
+    >
+    ( typename detail::bind_tuple_mapper<
+        const Arg1, const Arg2, const Arg3, const Arg4, const Arg5,
+        const Arg6, const Arg7
+      >::type
+      (a1, a2, a3, a4, a5, a6, a7)
+    );
+}
+
+
+ #else 
+template <class Arg1, class Arg2, class Arg3, class Arg4, class Arg5,
+          class Arg6, class Arg7>
+inline const
+lambda_functor<
+  lambda_functor_base<
+    action<7, function_action<7> >,
+    typename detail::bind_tuple_mapper<
+      typename detail::constify_non_funcs<Arg1>::type, const Arg2, const Arg3,
+      const Arg4, const Arg5, const Arg6, const Arg7
+    >::type
+  >
+>
+
+bind(const Arg1& a1, const Arg2& a2, const Arg3& a3, const Arg4& a4,
+     const Arg5& a5, const Arg6& a6, const Arg7& a7) {
+  return
+    lambda_functor_base<
+      action<7, function_action<7> >,
+      typename detail::bind_tuple_mapper<
+        typename detail::constify_non_funcs<Arg1>::type, const Arg2,
+        const Arg3, const Arg4, const Arg5, const Arg6, const Arg7
+      >::type
+    >
+    ( typename detail::bind_tuple_mapper<
+        typename detail::constify_non_funcs<Arg1>::type, const Arg2,
+        const Arg3, const Arg4, const Arg5, const Arg6, const Arg7
+      >::type
+      (a1, a2, a3, a4, a5, a6, a7)
+    );
+}
+
+template <class Result, class Arg1, class Arg2, class Arg3, class Arg4,
+          class Arg5, class Arg6, class Arg7>
+inline const
+lambda_functor<
+  lambda_functor_base<
+    action<7, function_action<7, Result> >,
+    typename detail::bind_tuple_mapper<
+      typename detail::constify_non_funcs<Arg1>::type, const Arg2, const Arg3,
+      const Arg4, const Arg5, const Arg6, const Arg7
+    >::type
+  >
+>
+
+bind(const Arg1& a1, const Arg2& a2, const Arg3& a3, const Arg4& a4,
+     const Arg5& a5, const Arg6& a6, const Arg7& a7) {
+  return
+    lambda_functor_base<
+      action<7, function_action<7, Result> >,
+      typename detail::bind_tuple_mapper<
+        typename detail::constify_non_funcs<Arg1>::type, const Arg2,
+        const Arg3, const Arg4, const Arg5, const Arg6, const Arg7
+      >::type
+    >
+    ( typename detail::bind_tuple_mapper<
+        typename detail::constify_non_funcs<Arg1>::type, const Arg2,
+        const Arg3, const Arg4, const Arg5, const Arg6, const Arg7
+      >::type
+      (a1, a2, a3, a4, a5, a6, a7)
+    );
+}
+
+template <class Result, class Par1, class Par2, class Par3, class Par4,
+          class Par5, class Par6, class Arg2, class Arg3, class Arg4,
+          class Arg5, class Arg6, class Arg7>
+inline const
+lambda_functor<
+  lambda_functor_base<
+    action<7, function_action<7, Result> >,
+    typename detail::bind_tuple_mapper<
+      Result(*)(Par1, Par2, Par3, Par4, Par5, Par6), const Arg2, const Arg3,
+      const Arg4, const Arg5, const Arg6, const Arg7
+    >::type
+  >
+>
+
+bind(Result(* const & a1)(Par1, Par2, Par3, Par4, Par5, Par6),
+     const Arg2& a2, const Arg3& a3, const Arg4& a4, const Arg5& a5,
+     const Arg6& a6, const Arg7& a7) {
+  return
+    lambda_functor_base<
+      action<7, function_action<7, Result> >,
+      typename detail::bind_tuple_mapper<
+        Result(*)(Par1, Par2, Par3, Par4, Par5, Par6), const Arg2, const Arg3,
+        const Arg4, const Arg5, const Arg6, const Arg7
+      >::type
+    >
+    ( typename detail::bind_tuple_mapper<
+        Result(*)(Par1, Par2, Par3, Par4, Par5, Par6), const Arg2, const Arg3,
+        const Arg4, const Arg5, const Arg6, const Arg7
+      >::type
+      (a1, a2, a3, a4, a5, a6, a7)
+    );
+}
+
+
+ #endif 
+
+// 8-argument bind functions --------------------------
+#ifndef BOOST_REF_TO_FUNC_CONFLICTS_WITH_REF_TO_T
+template <class Result, class Par1, class Par2, class Par3, class Par4,
+          class Par5, class Par6, class Par7, class Arg2, class Arg3,
+          class Arg4, class Arg5, class Arg6, class Arg7, class Arg8>
+inline const
+lambda_functor<
+  lambda_functor_base<
+    action<8, function_action<8, Result> >,
+    typename detail::bind_tuple_mapper<
+      Result(&)(Par1, Par2, Par3, Par4, Par5, Par6, Par7), const Arg2,
+      const Arg3, const Arg4, const Arg5, const Arg6, const Arg7, const Arg8
+    >::type
+  >
+>
+
+bind(Result(&a1)(Par1, Par2, Par3, Par4, Par5, Par6, Par7), const Arg2& a2,
+     const Arg3& a3, const Arg4& a4, const Arg5& a5, const Arg6& a6,
+     const Arg7& a7, const Arg8& a8) {
+  return
+    lambda_functor_base<
+      action<8, function_action<8, Result> >,
+      typename detail::bind_tuple_mapper<
+        Result(&)(Par1, Par2, Par3, Par4, Par5, Par6, Par7), const Arg2,
+        const Arg3, const Arg4, const Arg5, const Arg6, const Arg7, const Arg8
+      >::type
+    >
+    ( typename detail::bind_tuple_mapper<
+        Result(&)(Par1, Par2, Par3, Par4, Par5, Par6, Par7), const Arg2,
+        const Arg3, const Arg4, const Arg5, const Arg6, const Arg7, const Arg8
+      >::type
+      (a1, a2, a3, a4, a5, a6, a7, a8)
+    );
+}
+#endif
+
+ #ifndef BOOST_LAMBDA_INCORRECT_BIND_OVERLOADING 
+template <class Arg1, class Arg2, class Arg3, class Arg4, class Arg5,
+          class Arg6, class Arg7, class Arg8>
+inline const
+lambda_functor<
+  lambda_functor_base<
+    action<8, function_action<8> >,
+    typename detail::bind_tuple_mapper<
+      const Arg1, const Arg2, const Arg3, const Arg4, const Arg5, const Arg6,
+      const Arg7, const Arg8
+    >::type
+  >
+>
+
+bind(const Arg1& a1, const Arg2& a2, const Arg3& a3, const Arg4& a4,
+     const Arg5& a5, const Arg6& a6, const Arg7& a7, const Arg8& a8) {
+  return
+    lambda_functor_base<
+      action<8, function_action<8> >,
+      typename detail::bind_tuple_mapper<
+        const Arg1, const Arg2, const Arg3, const Arg4, const Arg5,
+        const Arg6, const Arg7, const Arg8
+      >::type
+    >
+    ( typename detail::bind_tuple_mapper<
+        const Arg1, const Arg2, const Arg3, const Arg4, const Arg5,
+        const Arg6, const Arg7, const Arg8
+      >::type
+      (a1, a2, a3, a4, a5, a6, a7, a8)
+    );
+}
+
+template <class Result, class Arg1, class Arg2, class Arg3, class Arg4,
+          class Arg5, class Arg6, class Arg7, class Arg8>
+inline const
+lambda_functor<
+  lambda_functor_base<
+    action<8, function_action<8, Result> >,
+    typename detail::bind_tuple_mapper<
+      const Arg1, const Arg2, const Arg3, const Arg4, const Arg5, const Arg6,
+      const Arg7, const Arg8
+    >::type
+  >
+>
+
+bind(const Arg1& a1, const Arg2& a2, const Arg3& a3, const Arg4& a4,
+     const Arg5& a5, const Arg6& a6, const Arg7& a7, const Arg8& a8) {
+  return
+    lambda_functor_base<
+      action<8, function_action<8, Result> >,
+      typename detail::bind_tuple_mapper<
+        const Arg1, const Arg2, const Arg3, const Arg4, const Arg5,
+        const Arg6, const Arg7, const Arg8
+      >::type
+    >
+    ( typename detail::bind_tuple_mapper<
+        const Arg1, const Arg2, const Arg3, const Arg4, const Arg5,
+        const Arg6, const Arg7, const Arg8
+      >::type
+      (a1, a2, a3, a4, a5, a6, a7, a8)
+    );
+}
+
+
+ #else 
+template <class Arg1, class Arg2, class Arg3, class Arg4, class Arg5,
+          class Arg6, class Arg7, class Arg8>
+inline const
+lambda_functor<
+  lambda_functor_base<
+    action<8, function_action<8> >,
+    typename detail::bind_tuple_mapper<
+      typename detail::constify_non_funcs<Arg1>::type, const Arg2, const Arg3,
+      const Arg4, const Arg5, const Arg6, const Arg7, const Arg8
+    >::type
+  >
+>
+
+bind(const Arg1& a1, const Arg2& a2, const Arg3& a3, const Arg4& a4,
+     const Arg5& a5, const Arg6& a6, const Arg7& a7, const Arg8& a8) {
+  return
+    lambda_functor_base<
+      action<8, function_action<8> >,
+      typename detail::bind_tuple_mapper<
+        typename detail::constify_non_funcs<Arg1>::type, const Arg2,
+        const Arg3, const Arg4, const Arg5, const Arg6, const Arg7, const Arg8
+      >::type
+    >
+    ( typename detail::bind_tuple_mapper<
+        typename detail::constify_non_funcs<Arg1>::type, const Arg2,
+        const Arg3, const Arg4, const Arg5, const Arg6, const Arg7, const Arg8
+      >::type
+      (a1, a2, a3, a4, a5, a6, a7, a8)
+    );
+}
+
+template <class Result, class Arg1, class Arg2, class Arg3, class Arg4,
+          class Arg5, class Arg6, class Arg7, class Arg8>
+inline const
+lambda_functor<
+  lambda_functor_base<
+    action<8, function_action<8, Result> >,
+    typename detail::bind_tuple_mapper<
+      typename detail::constify_non_funcs<Arg1>::type, const Arg2, const Arg3,
+      const Arg4, const Arg5, const Arg6, const Arg7, const Arg8
+    >::type
+  >
+>
+
+bind(const Arg1& a1, const Arg2& a2, const Arg3& a3, const Arg4& a4,
+     const Arg5& a5, const Arg6& a6, const Arg7& a7, const Arg8& a8) {
+  return
+    lambda_functor_base<
+      action<8, function_action<8, Result> >,
+      typename detail::bind_tuple_mapper<
+        typename detail::constify_non_funcs<Arg1>::type, const Arg2,
+        const Arg3, const Arg4, const Arg5, const Arg6, const Arg7, const Arg8
+      >::type
+    >
+    ( typename detail::bind_tuple_mapper<
+        typename detail::constify_non_funcs<Arg1>::type, const Arg2,
+        const Arg3, const Arg4, const Arg5, const Arg6, const Arg7, const Arg8
+      >::type
+      (a1, a2, a3, a4, a5, a6, a7, a8)
+    );
+}
+
+template <class Result, class Par1, class Par2, class Par3, class Par4,
+          class Par5, class Par6, class Par7, class Arg2, class Arg3,
+          class Arg4, class Arg5, class Arg6, class Arg7, class Arg8>
+inline const
+lambda_functor<
+  lambda_functor_base<
+    action<8, function_action<8, Result> >,
+    typename detail::bind_tuple_mapper<
+      Result(*)(Par1, Par2, Par3, Par4, Par5, Par6, Par7), const Arg2,
+      const Arg3, const Arg4, const Arg5, const Arg6, const Arg7, const Arg8
+    >::type
+  >
+>
+
+bind(Result(* const & a1)(Par1, Par2, Par3, Par4, Par5, Par6, Par7),
+     const Arg2& a2, const Arg3& a3, const Arg4& a4, const Arg5& a5,
+     const Arg6& a6, const Arg7& a7, const Arg8& a8) {
+  return
+    lambda_functor_base<
+      action<8, function_action<8, Result> >,
+      typename detail::bind_tuple_mapper<
+        Result(*)(Par1, Par2, Par3, Par4, Par5, Par6, Par7), const Arg2,
+        const Arg3, const Arg4, const Arg5, const Arg6, const Arg7, const Arg8
+      >::type
+    >
+    ( typename detail::bind_tuple_mapper<
+        Result(*)(Par1, Par2, Par3, Par4, Par5, Par6, Par7), const Arg2,
+        const Arg3, const Arg4, const Arg5, const Arg6, const Arg7, const Arg8
+      >::type
+      (a1, a2, a3, a4, a5, a6, a7, a8)
+    );
+}
+
+
+ #endif 
+
+// 9-argument bind functions --------------------------
+#ifndef BOOST_REF_TO_FUNC_CONFLICTS_WITH_REF_TO_T
+template <class Result, class Par1, class Par2, class Par3, class Par4,
+          class Par5, class Par6, class Par7, class Par8, class Arg2,
+          class Arg3, class Arg4, class Arg5, class Arg6, class Arg7,
+          class Arg8, class Arg9>
+inline const
+lambda_functor<
+  lambda_functor_base<
+    action<9, function_action<9, Result> >,
+    typename detail::bind_tuple_mapper<
+      Result(&)(Par1, Par2, Par3, Par4, Par5, Par6, Par7, Par8), const Arg2,
+      const Arg3, const Arg4, const Arg5, const Arg6, const Arg7, const Arg8,
+      const Arg9
+    >::type
+  >
+>
+
+bind(Result(&a1)(Par1, Par2, Par3, Par4, Par5, Par6, Par7, Par8),
+     const Arg2& a2, const Arg3& a3, const Arg4& a4, const Arg5& a5,
+     const Arg6& a6, const Arg7& a7, const Arg8& a8, const Arg9& a9) {
+  return
+    lambda_functor_base<
+      action<9, function_action<9, Result> >,
+      typename detail::bind_tuple_mapper<
+        Result(&)(Par1, Par2, Par3, Par4, Par5, Par6, Par7, Par8), const Arg2,
+        const Arg3, const Arg4, const Arg5, const Arg6, const Arg7,
+        const Arg8, const Arg9
+      >::type
+    >
+    ( typename detail::bind_tuple_mapper<
+        Result(&)(Par1, Par2, Par3, Par4, Par5, Par6, Par7, Par8), const Arg2,
+        const Arg3, const Arg4, const Arg5, const Arg6, const Arg7,
+        const Arg8, const Arg9
+      >::type
+      (a1, a2, a3, a4, a5, a6, a7, a8, a9)
+    );
+}
+#endif
+
+ #ifndef BOOST_LAMBDA_INCORRECT_BIND_OVERLOADING 
+template <class Arg1, class Arg2, class Arg3, class Arg4, class Arg5,
+          class Arg6, class Arg7, class Arg8, class Arg9>
+inline const
+lambda_functor<
+  lambda_functor_base<
+    action<9, function_action<9> >,
+    typename detail::bind_tuple_mapper<
+      const Arg1, const Arg2, const Arg3, const Arg4, const Arg5, const Arg6,
+      const Arg7, const Arg8, const Arg9
+    >::type
+  >
+>
+
+bind(const Arg1& a1, const Arg2& a2, const Arg3& a3, const Arg4& a4,
+     const Arg5& a5, const Arg6& a6, const Arg7& a7, const Arg8& a8,
+     const Arg9& a9) {
+  return
+    lambda_functor_base<
+      action<9, function_action<9> >,
+      typename detail::bind_tuple_mapper<
+        const Arg1, const Arg2, const Arg3, const Arg4, const Arg5,
+        const Arg6, const Arg7, const Arg8, const Arg9
+      >::type
+    >
+    ( typename detail::bind_tuple_mapper<
+        const Arg1, const Arg2, const Arg3, const Arg4, const Arg5,
+        const Arg6, const Arg7, const Arg8, const Arg9
+      >::type
+      (a1, a2, a3, a4, a5, a6, a7, a8, a9)
+    );
+}
+
+template <class Result, class Arg1, class Arg2, class Arg3, class Arg4,
+          class Arg5, class Arg6, class Arg7, class Arg8, class Arg9>
+inline const
+lambda_functor<
+  lambda_functor_base<
+    action<9, function_action<9, Result> >,
+    typename detail::bind_tuple_mapper<
+      const Arg1, const Arg2, const Arg3, const Arg4, const Arg5, const Arg6,
+      const Arg7, const Arg8, const Arg9
+    >::type
+  >
+>
+
+bind(const Arg1& a1, const Arg2& a2, const Arg3& a3, const Arg4& a4,
+     const Arg5& a5, const Arg6& a6, const Arg7& a7, const Arg8& a8,
+     const Arg9& a9) {
+  return
+    lambda_functor_base<
+      action<9, function_action<9, Result> >,
+      typename detail::bind_tuple_mapper<
+        const Arg1, const Arg2, const Arg3, const Arg4, const Arg5,
+        const Arg6, const Arg7, const Arg8, const Arg9
+      >::type
+    >
+    ( typename detail::bind_tuple_mapper<
+        const Arg1, const Arg2, const Arg3, const Arg4, const Arg5,
+        const Arg6, const Arg7, const Arg8, const Arg9
+      >::type
+      (a1, a2, a3, a4, a5, a6, a7, a8, a9)
+    );
+}
+
+
+ #else 
+template <class Arg1, class Arg2, class Arg3, class Arg4, class Arg5,
+          class Arg6, class Arg7, class Arg8, class Arg9>
+inline const
+lambda_functor<
+  lambda_functor_base<
+    action<9, function_action<9> >,
+    typename detail::bind_tuple_mapper<
+      typename detail::constify_non_funcs<Arg1>::type, const Arg2, const Arg3,
+      const Arg4, const Arg5, const Arg6, const Arg7, const Arg8, const Arg9
+    >::type
+  >
+>
+
+bind(const Arg1& a1, const Arg2& a2, const Arg3& a3, const Arg4& a4,
+     const Arg5& a5, const Arg6& a6, const Arg7& a7, const Arg8& a8,
+     const Arg9& a9) {
+  return
+    lambda_functor_base<
+      action<9, function_action<9> >,
+      typename detail::bind_tuple_mapper<
+        typename detail::constify_non_funcs<Arg1>::type, const Arg2,
+        const Arg3, const Arg4, const Arg5, const Arg6, const Arg7,
+        const Arg8, const Arg9
+      >::type
+    >
+    ( typename detail::bind_tuple_mapper<
+        typename detail::constify_non_funcs<Arg1>::type, const Arg2,
+        const Arg3, const Arg4, const Arg5, const Arg6, const Arg7,
+        const Arg8, const Arg9
+      >::type
+      (a1, a2, a3, a4, a5, a6, a7, a8, a9)
+    );
+}
+
+template <class Result, class Arg1, class Arg2, class Arg3, class Arg4,
+          class Arg5, class Arg6, class Arg7, class Arg8, class Arg9>
+inline const
+lambda_functor<
+  lambda_functor_base<
+    action<9, function_action<9, Result> >,
+    typename detail::bind_tuple_mapper<
+      typename detail::constify_non_funcs<Arg1>::type, const Arg2, const Arg3,
+      const Arg4, const Arg5, const Arg6, const Arg7, const Arg8, const Arg9
+    >::type
+  >
+>
+
+bind(const Arg1& a1, const Arg2& a2, const Arg3& a3, const Arg4& a4,
+     const Arg5& a5, const Arg6& a6, const Arg7& a7, const Arg8& a8,
+     const Arg9& a9) {
+  return
+    lambda_functor_base<
+      action<9, function_action<9, Result> >,
+      typename detail::bind_tuple_mapper<
+        typename detail::constify_non_funcs<Arg1>::type, const Arg2,
+        const Arg3, const Arg4, const Arg5, const Arg6, const Arg7,
+        const Arg8, const Arg9
+      >::type
+    >
+    ( typename detail::bind_tuple_mapper<
+        typename detail::constify_non_funcs<Arg1>::type, const Arg2,
+        const Arg3, const Arg4, const Arg5, const Arg6, const Arg7,
+        const Arg8, const Arg9
+      >::type
+      (a1, a2, a3, a4, a5, a6, a7, a8, a9)
+    );
+}
+
+template <class Result, class Par1, class Par2, class Par3, class Par4,
+          class Par5, class Par6, class Par7, class Par8, class Arg2,
+          class Arg3, class Arg4, class Arg5, class Arg6, class Arg7,
+          class Arg8, class Arg9>
+inline const
+lambda_functor<
+  lambda_functor_base<
+    action<9, function_action<9, Result> >,
+    typename detail::bind_tuple_mapper<
+      Result(*)(Par1, Par2, Par3, Par4, Par5, Par6, Par7, Par8), const Arg2,
+      const Arg3, const Arg4, const Arg5, const Arg6, const Arg7, const Arg8,
+      const Arg9
+    >::type
+  >
+>
+
+bind(Result(* const & a1)(Par1, Par2, Par3, Par4, Par5, Par6, Par7, Par8),
+     const Arg2& a2, const Arg3& a3, const Arg4& a4, const Arg5& a5,
+     const Arg6& a6, const Arg7& a7, const Arg8& a8, const Arg9& a9) {
+  return
+    lambda_functor_base<
+      action<9, function_action<9, Result> >,
+      typename detail::bind_tuple_mapper<
+        Result(*)(Par1, Par2, Par3, Par4, Par5, Par6, Par7, Par8), const Arg2,
+        const Arg3, const Arg4, const Arg5, const Arg6, const Arg7,
+        const Arg8, const Arg9
+      >::type
+    >
+    ( typename detail::bind_tuple_mapper<
+        Result(*)(Par1, Par2, Par3, Par4, Par5, Par6, Par7, Par8), const Arg2,
+        const Arg3, const Arg4, const Arg5, const Arg6, const Arg7,
+        const Arg8, const Arg9
+      >::type
+      (a1, a2, a3, a4, a5, a6, a7, a8, a9)
+    );
+}
+
+
+ #endif 
+
+// 10-argument bind functions --------------------------
+#ifndef BOOST_REF_TO_FUNC_CONFLICTS_WITH_REF_TO_T
+template <class Result, class Par1, class Par2, class Par3, class Par4,
+          class Par5, class Par6, class Par7, class Par8, class Par9,
+          class Arg2, class Arg3, class Arg4, class Arg5, class Arg6,
+          class Arg7, class Arg8, class Arg9, class Arg10>
+inline const
+lambda_functor<
+  lambda_functor_base<
+    action<10, function_action<10, Result> >,
+    typename detail::bind_tuple_mapper<
+      Result(&)(Par1, Par2, Par3, Par4, Par5, Par6, Par7, Par8, Par9),
+      const Arg2, const Arg3, const Arg4, const Arg5, const Arg6, const Arg7,
+      const Arg8, const Arg9, const Arg10
+    >::type
+  >
+>
+
+bind(Result(&a1)(Par1, Par2, Par3, Par4, Par5, Par6, Par7, Par8, Par9),
+     const Arg2& a2, const Arg3& a3, const Arg4& a4, const Arg5& a5,
+     const Arg6& a6, const Arg7& a7, const Arg8& a8, const Arg9& a9,
+     const Arg10& a10) {
+  return
+    lambda_functor_base<
+      action<10, function_action<10, Result> >,
+      typename detail::bind_tuple_mapper<
+        Result(&)(Par1, Par2, Par3, Par4, Par5, Par6, Par7, Par8, Par9),
+        const Arg2, const Arg3, const Arg4, const Arg5, const Arg6,
+        const Arg7, const Arg8, const Arg9, const Arg10
+      >::type
+    >
+    ( typename detail::bind_tuple_mapper<
+        Result(&)(Par1, Par2, Par3, Par4, Par5, Par6, Par7, Par8, Par9),
+        const Arg2, const Arg3, const Arg4, const Arg5, const Arg6,
+        const Arg7, const Arg8, const Arg9, const Arg10
+      >::type
+      (a1, a2, a3, a4, a5, a6, a7, a8, a9, a10)
+    );
+}
+#endif
+
+ #ifndef BOOST_LAMBDA_INCORRECT_BIND_OVERLOADING 
+template <class Arg1, class Arg2, class Arg3, class Arg4, class Arg5,
+          class Arg6, class Arg7, class Arg8, class Arg9, class Arg10>
+inline const
+lambda_functor<
+  lambda_functor_base<
+    action<10, function_action<10> >,
+    typename detail::bind_tuple_mapper<
+      const Arg1, const Arg2, const Arg3, const Arg4, const Arg5, const Arg6,
+      const Arg7, const Arg8, const Arg9, const Arg10
+    >::type
+  >
+>
+
+bind(const Arg1& a1, const Arg2& a2, const Arg3& a3, const Arg4& a4,
+     const Arg5& a5, const Arg6& a6, const Arg7& a7, const Arg8& a8,
+     const Arg9& a9, const Arg10& a10) {
+  return
+    lambda_functor_base<
+      action<10, function_action<10> >,
+      typename detail::bind_tuple_mapper<
+        const Arg1, const Arg2, const Arg3, const Arg4, const Arg5,
+        const Arg6, const Arg7, const Arg8, const Arg9, const Arg10
+      >::type
+    >
+    ( typename detail::bind_tuple_mapper<
+        const Arg1, const Arg2, const Arg3, const Arg4, const Arg5,
+        const Arg6, const Arg7, const Arg8, const Arg9, const Arg10
+      >::type
+      (a1, a2, a3, a4, a5, a6, a7, a8, a9, a10)
+    );
+}
+
+template <class Result, class Arg1, class Arg2, class Arg3, class Arg4,
+          class Arg5, class Arg6, class Arg7, class Arg8, class Arg9,
+          class Arg10>
+inline const
+lambda_functor<
+  lambda_functor_base<
+    action<10, function_action<10, Result> >,
+    typename detail::bind_tuple_mapper<
+      const Arg1, const Arg2, const Arg3, const Arg4, const Arg5, const Arg6,
+      const Arg7, const Arg8, const Arg9, const Arg10
+    >::type
+  >
+>
+
+bind(const Arg1& a1, const Arg2& a2, const Arg3& a3, const Arg4& a4,
+     const Arg5& a5, const Arg6& a6, const Arg7& a7, const Arg8& a8,
+     const Arg9& a9, const Arg10& a10) {
+  return
+    lambda_functor_base<
+      action<10, function_action<10, Result> >,
+      typename detail::bind_tuple_mapper<
+        const Arg1, const Arg2, const Arg3, const Arg4, const Arg5,
+        const Arg6, const Arg7, const Arg8, const Arg9, const Arg10
+      >::type
+    >
+    ( typename detail::bind_tuple_mapper<
+        const Arg1, const Arg2, const Arg3, const Arg4, const Arg5,
+        const Arg6, const Arg7, const Arg8, const Arg9, const Arg10
+      >::type
+      (a1, a2, a3, a4, a5, a6, a7, a8, a9, a10)
+    );
+}
+
+
+ #else 
+template <class Arg1, class Arg2, class Arg3, class Arg4, class Arg5,
+          class Arg6, class Arg7, class Arg8, class Arg9, class Arg10>
+inline const
+lambda_functor<
+  lambda_functor_base<
+    action<10, function_action<10> >,
+    typename detail::bind_tuple_mapper<
+      typename detail::constify_non_funcs<Arg1>::type, const Arg2, const Arg3,
+      const Arg4, const Arg5, const Arg6, const Arg7, const Arg8, const Arg9,
+      const Arg10
+    >::type
+  >
+>
+
+bind(const Arg1& a1, const Arg2& a2, const Arg3& a3, const Arg4& a4,
+     const Arg5& a5, const Arg6& a6, const Arg7& a7, const Arg8& a8,
+     const Arg9& a9, const Arg10& a10) {
+  return
+    lambda_functor_base<
+      action<10, function_action<10> >,
+      typename detail::bind_tuple_mapper<
+        typename detail::constify_non_funcs<Arg1>::type, const Arg2,
+        const Arg3, const Arg4, const Arg5, const Arg6, const Arg7,
+        const Arg8, const Arg9, const Arg10
+      >::type
+    >
+    ( typename detail::bind_tuple_mapper<
+        typename detail::constify_non_funcs<Arg1>::type, const Arg2,
+        const Arg3, const Arg4, const Arg5, const Arg6, const Arg7,
+        const Arg8, const Arg9, const Arg10
+      >::type
+      (a1, a2, a3, a4, a5, a6, a7, a8, a9, a10)
+    );
+}
+
+template <class Result, class Arg1, class Arg2, class Arg3, class Arg4,
+          class Arg5, class Arg6, class Arg7, class Arg8, class Arg9,
+          class Arg10>
+inline const
+lambda_functor<
+  lambda_functor_base<
+    action<10, function_action<10, Result> >,
+    typename detail::bind_tuple_mapper<
+      typename detail::constify_non_funcs<Arg1>::type, const Arg2, const Arg3,
+      const Arg4, const Arg5, const Arg6, const Arg7, const Arg8, const Arg9,
+      const Arg10
+    >::type
+  >
+>
+
+bind(const Arg1& a1, const Arg2& a2, const Arg3& a3, const Arg4& a4,
+     const Arg5& a5, const Arg6& a6, const Arg7& a7, const Arg8& a8,
+     const Arg9& a9, const Arg10& a10) {
+  return
+    lambda_functor_base<
+      action<10, function_action<10, Result> >,
+      typename detail::bind_tuple_mapper<
+        typename detail::constify_non_funcs<Arg1>::type, const Arg2,
+        const Arg3, const Arg4, const Arg5, const Arg6, const Arg7,
+        const Arg8, const Arg9, const Arg10
+      >::type
+    >
+    ( typename detail::bind_tuple_mapper<
+        typename detail::constify_non_funcs<Arg1>::type, const Arg2,
+        const Arg3, const Arg4, const Arg5, const Arg6, const Arg7,
+        const Arg8, const Arg9, const Arg10
+      >::type
+      (a1, a2, a3, a4, a5, a6, a7, a8, a9, a10)
+    );
+}
+
+template <class Result, class Par1, class Par2, class Par3, class Par4,
+          class Par5, class Par6, class Par7, class Par8, class Par9,
+          class Arg2, class Arg3, class Arg4, class Arg5, class Arg6,
+          class Arg7, class Arg8, class Arg9, class Arg10>
+inline const
+lambda_functor<
+  lambda_functor_base<
+    action<10, function_action<10, Result> >,
+    typename detail::bind_tuple_mapper<
+      Result(*)(Par1, Par2, Par3, Par4, Par5, Par6, Par7, Par8, Par9),
+      const Arg2, const Arg3, const Arg4, const Arg5, const Arg6, const Arg7,
+      const Arg8, const Arg9, const Arg10
+    >::type
+  >
+>
+
+bind(Result(* const & a1)(Par1, Par2, Par3, Par4, Par5, Par6, Par7, Par8,
+     Par9), const Arg2& a2, const Arg3& a3, const Arg4& a4, const Arg5& a5,
+     const Arg6& a6, const Arg7& a7, const Arg8& a8, const Arg9& a9,
+     const Arg10& a10) {
+  return
+    lambda_functor_base<
+      action<10, function_action<10, Result> >,
+      typename detail::bind_tuple_mapper<
+        Result(*)(Par1, Par2, Par3, Par4, Par5, Par6, Par7, Par8, Par9),
+        const Arg2, const Arg3, const Arg4, const Arg5, const Arg6,
+        const Arg7, const Arg8, const Arg9, const Arg10
+      >::type
+    >
+    ( typename detail::bind_tuple_mapper<
+        Result(*)(Par1, Par2, Par3, Par4, Par5, Par6, Par7, Par8, Par9),
+        const Arg2, const Arg3, const Arg4, const Arg5, const Arg6,
+        const Arg7, const Arg8, const Arg9, const Arg10
+      >::type
+      (a1, a2, a3, a4, a5, a6, a7, a8, a9, a10)
+    );
+}
+
+
+ #endif 
+
+} // namespace lambda 
+} // namespace ndnboost
+
+#endif
diff --git a/ndnboost/lambda/detail/function_adaptors.hpp b/ndnboost/lambda/detail/function_adaptors.hpp
new file mode 100644
index 0000000..df5367e
--- /dev/null
+++ b/ndnboost/lambda/detail/function_adaptors.hpp
@@ -0,0 +1,789 @@
+// Boost Lambda Library -  function_adaptors.hpp ----------------------------
+ 
+// Copyright (C) 1999, 2000 Jaakko Jarvi (jaakko.jarvi@cs.utu.fi)
+//
+// Distributed under the Boost Software License, Version 1.0. (See
+// accompanying file LICENSE_1_0.txt or copy at
+// http://www.boost.org/LICENSE_1_0.txt)
+//
+// For more information, see www.boost.org
+
+
+#ifndef BOOST_LAMBDA_FUNCTION_ADAPTORS_HPP
+#define BOOST_LAMBDA_FUNCTION_ADAPTORS_HPP
+
+#include "ndnboost/mpl/has_xxx.hpp"
+#include "ndnboost/tuple/tuple.hpp"
+#include "ndnboost/type_traits/same_traits.hpp"
+#include "ndnboost/type_traits/remove_reference.hpp"
+#include "ndnboost/type_traits/remove_cv.hpp"
+#include "ndnboost/type_traits/add_const.hpp"
+#include "ndnboost/type_traits/add_volatile.hpp"
+#include "ndnboost/utility/result_of.hpp"
+
+namespace ndnboost { 
+namespace lambda {
+
+namespace detail {
+
+BOOST_MPL_HAS_XXX_TEMPLATE_DEF(sig)
+
+template<class Tuple>
+struct remove_references_from_elements {
+  typedef typename ndnboost::tuples::cons<
+    typename ndnboost::remove_reference<typename Tuple::head_type>::type,
+    typename remove_references_from_elements<typename Tuple::tail_type>::type
+  > type;
+};
+
+template<>
+struct remove_references_from_elements<ndnboost::tuples::null_type> {
+  typedef ndnboost::tuples::null_type type;
+};
+
+}
+
+template <class Func> struct function_adaptor {
+
+  typedef typename detail::remove_reference_and_cv<Func>::type plainF;
+
+#if !defined(BOOST_NO_RESULT_OF)
+  // Support functors that use the ndnboost::result_of return type convention.
+  template<class Tuple, int Length, bool HasSig>
+  struct result_converter;
+  template<class Tuple, int Length>
+  struct result_converter<Tuple, Length, true>
+    : plainF::template sig<
+        typename detail::remove_references_from_elements<Tuple>::type
+      >
+  {};
+  template<class Tuple>
+  struct result_converter<Tuple, 0, false>
+    : result_of<plainF()>
+  {};
+  template<class Tuple>
+  struct result_converter<Tuple, 1, false>
+    : result_of<plainF(
+        typename tuples::element<1, Tuple>::type)
+      >
+  {};
+  template<class Tuple>
+  struct result_converter<Tuple, 2, false>
+    : result_of<plainF(
+        typename tuples::element<1, Tuple>::type,
+        typename tuples::element<2, Tuple>::type)
+      >
+  {};
+  template<class Tuple>
+  struct result_converter<Tuple, 3, false>
+    : result_of<plainF(
+        typename tuples::element<1, Tuple>::type,
+        typename tuples::element<2, Tuple>::type,
+        typename tuples::element<3, Tuple>::type)
+      >
+  {};
+  template<class Tuple>
+  struct result_converter<Tuple, 4, false>
+    : result_of<plainF(
+        typename tuples::element<1, Tuple>::type,
+        typename tuples::element<2, Tuple>::type,
+        typename tuples::element<3, Tuple>::type,
+        typename tuples::element<4, Tuple>::type)
+      >
+  {};
+  template<class Tuple>
+  struct result_converter<Tuple, 5, false>
+    : result_of<plainF(
+        typename tuples::element<1, Tuple>::type,
+        typename tuples::element<2, Tuple>::type,
+        typename tuples::element<3, Tuple>::type,
+        typename tuples::element<4, Tuple>::type,
+        typename tuples::element<5, Tuple>::type)
+      >
+  {};
+  template<class Tuple>
+  struct result_converter<Tuple, 6, false>
+    : result_of<plainF(
+        typename tuples::element<1, Tuple>::type,
+        typename tuples::element<2, Tuple>::type,
+        typename tuples::element<3, Tuple>::type,
+        typename tuples::element<4, Tuple>::type,
+        typename tuples::element<5, Tuple>::type,
+        typename tuples::element<6, Tuple>::type)
+      >
+  {};
+  template<class Tuple>
+  struct result_converter<Tuple, 7, false>
+    : result_of<plainF(
+        typename tuples::element<1, Tuple>::type,
+        typename tuples::element<2, Tuple>::type,
+        typename tuples::element<3, Tuple>::type,
+        typename tuples::element<4, Tuple>::type,
+        typename tuples::element<5, Tuple>::type,
+        typename tuples::element<6, Tuple>::type,
+        typename tuples::element<7, Tuple>::type)
+      >
+  {};
+  template<class Tuple>
+  struct result_converter<Tuple, 8, false>
+    : result_of<plainF(
+        typename tuples::element<1, Tuple>::type,
+        typename tuples::element<2, Tuple>::type,
+        typename tuples::element<3, Tuple>::type,
+        typename tuples::element<4, Tuple>::type,
+        typename tuples::element<5, Tuple>::type,
+        typename tuples::element<6, Tuple>::type,
+        typename tuples::element<7, Tuple>::type,
+        typename tuples::element<8, Tuple>::type)
+      >
+  {};
+  template<class Tuple>
+  struct result_converter<Tuple, 9, false>
+    : result_of<plainF(
+        typename tuples::element<1, Tuple>::type,
+        typename tuples::element<2, Tuple>::type,
+        typename tuples::element<3, Tuple>::type,
+        typename tuples::element<4, Tuple>::type,
+        typename tuples::element<5, Tuple>::type,
+        typename tuples::element<6, Tuple>::type,
+        typename tuples::element<7, Tuple>::type,
+        typename tuples::element<8, Tuple>::type,
+        typename tuples::element<9, Tuple>::type)
+      >
+  {};
+
+  // we do not know the return type off-hand, we must ask it from Func
+  // To sig we pass a cons list, where the head is the function object type
+  // itself (potentially cv-qualified)
+  // and the tail contains the types of the actual arguments to be passed
+  // to the function object. The arguments can be cv qualified
+  // as well.
+  template <class Args>
+  struct sig
+    : result_converter<
+        Args
+      , tuples::length<typename Args::tail_type>::value
+      , detail::has_sig<plainF>::value
+      >
+  {};
+#else // BOOST_NO_RESULT_OF
+
+  template <class Args> class sig {
+    typedef typename detail::remove_reference_and_cv<Func>::type plainF;
+  public:
+    typedef typename plainF::template sig<
+      typename detail::remove_references_from_elements<Args>::type
+    >::type type;
+  };
+#endif
+
+  template<class RET, class A1>
+  static RET apply(A1& a1) {
+    return a1();
+  }
+  template<class RET, class A1, class A2>
+  static RET apply(A1& a1, A2& a2) {
+    return a1(a2);
+  }
+  template<class RET, class A1, class A2, class A3>
+  static RET apply(A1& a1, A2& a2, A3& a3) {
+    return a1(a2, a3);
+  }
+  template<class RET, class A1, class A2, class A3, class A4>
+  static RET apply(A1& a1, A2& a2, A3& a3, A4& a4) {
+    return a1(a2, a3, a4);
+  }
+  template<class RET, class A1, class A2, class A3, class A4, class A5>
+  static RET apply(A1& a1, A2& a2, A3& a3, A4& a4, A5& a5) {
+    return a1(a2, a3, a4, a5);
+  }
+  template<class RET, class A1, class A2, class A3, class A4, class A5, class A6>
+  static RET apply(A1& a1, A2& a2, A3& a3, A4& a4, A5& a5, A6& a6) {
+    return a1(a2, a3, a4, a5, a6);
+  }
+  template<class RET, class A1, class A2, class A3, class A4, class A5, class A6, 
+           class A7>
+  static RET apply(A1& a1, A2& a2, A3& a3, A4& a4, A5& a5, A6& a6, 
+                           A7& a7) {
+    return a1(a2, a3, a4, a5, a6, a7);
+  }
+  template<class RET, class A1, class A2, class A3, class A4, class A5, class A6, 
+           class A7, class A8>
+  static RET apply(A1& a1, A2& a2, A3& a3, A4& a4, A5& a5, A6& a6, 
+                           A7& a7, A8& a8) {
+    return a1(a2, a3, a4, a5, a6, a7, a8);
+  }
+  template<class RET, class A1, class A2, class A3, class A4, class A5, class A6, 
+           class A7, class A8, class A9>
+  static RET apply(A1& a1, A2& a2, A3& a3, A4& a4, A5& a5, A6& a6, 
+                           A7& a7, A8& a8, A9& a9) {
+    return a1(a2, a3, a4, a5, a6, a7, a8, a9);
+  }
+  template<class RET, class A1, class A2, class A3, class A4, class A5, class A6, 
+           class A7, class A8, class A9, class A10>
+  static RET apply(A1& a1, A2& a2, A3& a3, A4& a4, A5& a5, A6& a6, 
+                           A7& a7, A8& a8, A9& a9, A10& a10) {
+    return a1(a2, a3, a4, a5, a6, a7, a8, a9, a10);
+  }
+};
+
+template <class Func> struct function_adaptor<const Func>; // error 
+
+// -- function adaptors with data member access
+template <class Object, class T>
+struct function_adaptor<T Object::*> {
+
+  //  typedef detail::unspecified type;
+
+  // T can have qualifiers and can be a reference type
+  // We get the return type by adding const, if the object through which
+  // the data member is accessed is const, and finally adding a reference
+  template<class Args> class sig { 
+    typedef typename ndnboost::tuples::element<1, Args>::type argument_type;
+    typedef typename ndnboost::remove_reference<
+      argument_type
+    >::type unref_type;
+
+    typedef typename detail::IF<ndnboost::is_const<unref_type>::value,
+      typename ndnboost::add_const<T>::type,
+      T
+    >::RET properly_consted_return_type;
+
+    typedef typename detail::IF<ndnboost::is_volatile<unref_type>::value,
+      typename ndnboost::add_volatile<properly_consted_return_type>::type,
+      properly_consted_return_type
+    >::RET properly_cvd_return_type;
+
+
+  public:
+    typedef typename detail::IF<ndnboost::is_reference<argument_type>::value,
+      typename ndnboost::add_reference<properly_cvd_return_type>::type,
+      typename ndnboost::remove_cv<T>::type
+    >::RET type;
+  };
+
+  template <class RET>
+  static RET apply( T Object::*data, Object& o) {
+    return o.*data;
+  }
+  template <class RET>
+  static RET apply( T Object::*data, const Object& o) {
+    return o.*data;
+  }
+  template <class RET>
+  static RET apply( T Object::*data, volatile Object& o) {
+    return o.*data;
+  }
+  template <class RET>
+  static RET apply( T Object::*data, const volatile Object& o) {
+    return o.*data;
+  }
+  template <class RET>
+  static RET apply( T Object::*data, Object* o) {
+    return o->*data;
+  }
+  template <class RET>
+  static RET apply( T Object::*data, const Object* o) {
+    return o->*data;
+  }
+  template <class RET>
+  static RET apply( T Object::*data, volatile Object* o) {
+    return o->*data;
+  }
+  template <class RET>
+  static RET apply( T Object::*data, const volatile Object* o) {
+    return o->*data;
+  }
+};
+
+// -- function adaptors with 1 argument apply
+   
+template <class Result>
+struct function_adaptor<Result (void)> {
+  
+  template<class T> struct sig { typedef Result type; };
+  template <class RET>
+  static Result apply(Result (*func)()) {
+    return func();
+  }
+};
+
+template <class Result>
+struct function_adaptor<Result (*)(void)> {
+
+  template<class T> struct sig { typedef Result type; };
+  template <class RET>
+  static Result apply(Result (*func)()) {
+    return func();
+  }
+};
+
+
+// -- function adaptors with 2 argument apply
+template <class Object, class Result>
+struct function_adaptor<Result (Object::*)() const> {
+
+  template<class T> struct sig { typedef Result type; };
+  template <class RET>
+  static Result apply( Result (Object::*func)() const, const Object* o) {
+    return (o->*func)();
+  }
+  template <class RET>
+  static Result apply( Result (Object::*func)() const, const Object& o) {
+    return (o.*func)();
+  }
+};
+
+template <class Object, class Result>
+struct function_adaptor<Result (Object::*)()> {
+
+  template<class T> struct sig { typedef Result type; };
+  template <class RET>
+  static Result apply( Result (Object::*func)(), Object* o) {
+    return (o->*func)();
+  }
+  template <class RET>
+  static Result apply( Result (Object::*func)(), Object& o) {
+    return (o.*func)();
+  }
+};
+
+template <class Arg1, class Result>
+struct function_adaptor<Result (Arg1)> {
+
+  template<class T> struct sig { typedef Result type; };
+  template <class RET, class A1>
+  static Result apply(Result (*func)(Arg1), A1& a1) {
+    return func(a1);
+  }
+};
+
+template <class Arg1, class Result>
+struct function_adaptor<Result (*)(Arg1)> {
+
+  template<class T> struct sig { typedef Result type; };
+  template <class RET, class A1>
+  static Result apply(Result (*func)(Arg1), A1& a1) {
+    return func(a1);
+  }
+};
+
+
+// -- function adaptors with 3 argument apply
+template <class Object, class Arg1, class Result>
+struct function_adaptor<Result (Object::*)(Arg1) const> {
+
+  template<class T> struct sig { typedef Result type; };
+  template <class RET, class A1>
+  static Result apply( Result (Object::*func)(Arg1) const, const Object* o, 
+    A1& a1) {
+    return (o->*func)(a1);
+  }
+  template <class RET, class A1>
+  static Result apply( Result (Object::*func)(Arg1) const, const Object& o, 
+    A1& a1) {
+    return (o.*func)(a1);
+  }
+};
+
+template <class Object, class Arg1, class Result>
+struct function_adaptor<Result (Object::*)(Arg1)> {
+
+  template<class T> struct sig { typedef Result type; };
+  template <class RET, class A1>
+  static Result apply( Result (Object::*func)(Arg1), Object* o, A1& a1) {
+    return (o->*func)(a1);
+  }
+  template <class RET, class A1>
+  static Result apply( Result (Object::*func)(Arg1), Object& o, A1& a1) {
+    return (o.*func)(a1);
+  }
+};
+
+template <class Arg1, class Arg2, class Result>
+struct function_adaptor<Result (Arg1, Arg2)> {
+
+  template<class T> struct sig { typedef Result type; };
+  template <class RET, class A1, class A2>
+  static Result apply(Result (*func)(Arg1, Arg2), A1& a1, A2& a2) {
+    return func(a1, a2);
+  }
+};
+
+template <class Arg1, class Arg2, class Result>
+struct function_adaptor<Result (*)(Arg1, Arg2)> {
+
+  template<class T> struct sig { typedef Result type; };
+  template <class RET, class A1, class A2>
+  static Result apply(Result (*func)(Arg1, Arg2), A1& a1, A2& a2) {
+    return func(a1, a2);
+  }
+};
+
+
+// -- function adaptors with 4 argument apply
+template <class Object, class Arg1, class Arg2, class Result>
+struct function_adaptor<Result (Object::*)(Arg1, Arg2) const> {
+
+  template<class T> struct sig { typedef Result type; };
+  template <class RET, class A1, class A2>
+  static Result apply( Result (Object::*func)(Arg1, Arg2) const, const Object* o, A1& a1, A2& a2) {
+    return (o->*func)(a1, a2);
+  }
+  template <class RET, class A1, class A2>
+  static Result apply( Result (Object::*func)(Arg1, Arg2) const, const Object& o, A1& a1, A2& a2) {
+    return (o.*func)(a1, a2);
+  }
+};
+
+template <class Object, class Arg1, class Arg2, class Result>
+struct function_adaptor<Result (Object::*)(Arg1, Arg2)> {
+
+  template<class T> struct sig { typedef Result type; };
+  template <class RET, class A1, class A2>
+  static Result apply( Result (Object::*func)(Arg1, Arg2), Object* o, A1& a1, A2& a2) {
+    return (o->*func)(a1, a2);
+  }
+  template <class RET, class A1, class A2>
+  static Result apply( Result (Object::*func)(Arg1, Arg2), Object& o, A1& a1, A2& a2) {
+    return (o.*func)(a1, a2);
+  }
+};
+
+template <class Arg1, class Arg2, class Arg3, class Result>
+struct function_adaptor<Result (Arg1, Arg2, Arg3)> {
+
+  template<class T> struct sig { typedef Result type; };
+  template <class RET, class A1, class A2, class A3>
+  static Result apply(Result (*func)(Arg1, Arg2, Arg3), A1& a1, A2& a2, A3& a3) {
+    return func(a1, a2, a3);
+  }
+};
+
+template <class Arg1, class Arg2, class Arg3, class Result>
+struct function_adaptor<Result (*)(Arg1, Arg2, Arg3)> {
+
+  template<class T> struct sig { typedef Result type; };
+  template <class RET, class A1, class A2, class A3>
+  static Result apply(Result (*func)(Arg1, Arg2, Arg3), A1& a1, A2& a2, A3& a3) {
+    return func(a1, a2, a3);
+  }
+};
+
+
+// -- function adaptors with 5 argument apply
+template <class Object, class Arg1, class Arg2, class Arg3, class Result>
+struct function_adaptor<Result (Object::*)(Arg1, Arg2, Arg3) const> {
+
+  template<class T> struct sig { typedef Result type; };
+  template <class RET, class A1, class A2, class A3>
+  static Result apply( Result (Object::*func)(Arg1, Arg2, Arg3) const, const Object* o, A1& a1, A2& a2, A3& a3) {
+    return (o->*func)(a1, a2, a3);
+  }
+  template <class RET, class A1, class A2, class A3>
+  static Result apply( Result (Object::*func)(Arg1, Arg2, Arg3) const, const Object& o, A1& a1, A2& a2, A3& a3) {
+    return (o.*func)(a1, a2, a3);
+  }
+};
+
+template <class Object, class Arg1, class Arg2, class Arg3, class Result>
+struct function_adaptor<Result (Object::*)(Arg1, Arg2, Arg3)> {
+
+  template<class T> struct sig { typedef Result type; };
+  template <class RET, class A1, class A2, class A3>
+  static Result apply( Result (Object::*func)(Arg1, Arg2, Arg3), Object* o, A1& a1, A2& a2, A3& a3) {
+    return (o->*func)(a1, a2, a3);
+  }
+  template <class RET, class A1, class A2, class A3>
+  static Result apply( Result (Object::*func)(Arg1, Arg2, Arg3), Object& o, A1& a1, A2& a2, A3& a3) {
+    return (o.*func)(a1, a2, a3);
+  }
+};
+
+template <class Arg1, class Arg2, class Arg3, class Arg4, class Result>
+struct function_adaptor<Result (Arg1, Arg2, Arg3, Arg4)> {
+
+  template<class T> struct sig { typedef Result type; };
+  template <class RET, class A1, class A2, class A3, class A4>
+  static Result apply(Result (*func)(Arg1, Arg2, Arg3, Arg4), A1& a1, A2& a2, A3& a3, A4& a4) {
+    return func(a1, a2, a3, a4);
+  }
+};
+
+template <class Arg1, class Arg2, class Arg3, class Arg4, class Result>
+struct function_adaptor<Result (*)(Arg1, Arg2, Arg3, Arg4)> {
+
+  template<class T> struct sig { typedef Result type; };
+  template <class RET, class A1, class A2, class A3, class A4>
+  static Result apply(Result (*func)(Arg1, Arg2, Arg3, Arg4), A1& a1, A2& a2, A3& a3, A4& a4) {
+    return func(a1, a2, a3, a4);
+  }
+};
+
+
+// -- function adaptors with 6 argument apply
+template <class Object, class Arg1, class Arg2, class Arg3, class Arg4, class Result>
+struct function_adaptor<Result (Object::*)(Arg1, Arg2, Arg3, Arg4) const> {
+
+  template<class T> struct sig { typedef Result type; };
+  template <class RET, class A1, class A2, class A3, class A4>
+  static Result apply( Result (Object::*func)(Arg1, Arg2, Arg3, Arg4) const, const Object* o, A1& a1, A2& a2, A3& a3, A4& a4) {
+    return (o->*func)(a1, a2, a3, a4);
+  }
+  template <class RET, class A1, class A2, class A3, class A4>
+  static Result apply( Result (Object::*func)(Arg1, Arg2, Arg3, Arg4) const, const Object& o, A1& a1, A2& a2, A3& a3, A4& a4) {
+    return (o.*func)(a1, a2, a3, a4);
+  }
+};
+
+template <class Object, class Arg1, class Arg2, class Arg3, class Arg4, class Result>
+struct function_adaptor<Result (Object::*)(Arg1, Arg2, Arg3, Arg4)> {
+
+  template<class T> struct sig { typedef Result type; };
+  template <class RET, class A1, class A2, class A3, class A4>
+  static Result apply( Result (Object::*func)(Arg1, Arg2, Arg3, Arg4), Object* o, A1& a1, A2& a2, A3& a3, A4& a4) {
+    return (o->*func)(a1, a2, a3, a4);
+  }
+  template <class RET, class A1, class A2, class A3, class A4>
+  static Result apply( Result (Object::*func)(Arg1, Arg2, Arg3, Arg4), Object& o, A1& a1, A2& a2, A3& a3, A4& a4) {
+    return (o.*func)(a1, a2, a3, a4);
+  }
+};
+
+template <class Arg1, class Arg2, class Arg3, class Arg4, class Arg5, class Result>
+struct function_adaptor<Result (Arg1, Arg2, Arg3, Arg4, Arg5)> {
+
+  template<class T> struct sig { typedef Result type; };
+  template <class RET, class A1, class A2, class A3, class A4, class A5>
+  static Result apply(Result (*func)(Arg1, Arg2, Arg3, Arg4, Arg5), A1& a1, A2& a2, A3& a3, A4& a4, A5& a5) {
+    return func(a1, a2, a3, a4, a5);
+  }
+};
+
+template <class Arg1, class Arg2, class Arg3, class Arg4, class Arg5, class Result>
+struct function_adaptor<Result (*)(Arg1, Arg2, Arg3, Arg4, Arg5)> {
+
+  template<class T> struct sig { typedef Result type; };
+  template <class RET, class A1, class A2, class A3, class A4, class A5>
+  static Result apply(Result (*func)(Arg1, Arg2, Arg3, Arg4, Arg5), A1& a1, A2& a2, A3& a3, A4& a4, A5& a5) {
+    return func(a1, a2, a3, a4, a5);
+  }
+};
+
+
+// -- function adaptors with 7 argument apply
+template <class Object, class Arg1, class Arg2, class Arg3, class Arg4, class Arg5, class Result>
+struct function_adaptor<Result (Object::*)(Arg1, Arg2, Arg3, Arg4, Arg5) const> {
+
+  template<class T> struct sig { typedef Result type; };
+  template <class RET, class A1, class A2, class A3, class A4, class A5>
+  static Result apply( Result (Object::*func)(Arg1, Arg2, Arg3, Arg4, Arg5) const, const Object* o, A1& a1, A2& a2, A3& a3, A4& a4, A5& a5) {
+    return (o->*func)(a1, a2, a3, a4, a5);
+  }
+  template <class RET, class A1, class A2, class A3, class A4, class A5>
+  static Result apply( Result (Object::*func)(Arg1, Arg2, Arg3, Arg4, Arg5) const, const Object& o, A1& a1, A2& a2, A3& a3, A4& a4, A5& a5) {
+    return (o.*func)(a1, a2, a3, a4, a5);
+  }
+};
+
+template <class Object, class Arg1, class Arg2, class Arg3, class Arg4, class Arg5, class Result>
+struct function_adaptor<Result (Object::*)(Arg1, Arg2, Arg3, Arg4, Arg5)> {
+
+  template<class T> struct sig { typedef Result type; };
+  template <class RET, class A1, class A2, class A3, class A4, class A5>
+  static Result apply( Result (Object::*func)(Arg1, Arg2, Arg3, Arg4, Arg5), Object* o, A1& a1, A2& a2, A3& a3, A4& a4, A5& a5) {
+    return (o->*func)(a1, a2, a3, a4, a5);
+  }
+  template <class RET, class A1, class A2, class A3, class A4, class A5>
+  static Result apply( Result (Object::*func)(Arg1, Arg2, Arg3, Arg4, Arg5), Object& o, A1& a1, A2& a2, A3& a3, A4& a4, A5& a5) {
+    return (o.*func)(a1, a2, a3, a4, a5);
+  }
+};
+
+template <class Arg1, class Arg2, class Arg3, class Arg4, class Arg5, class Arg6, class Result>
+struct function_adaptor<Result (Arg1, Arg2, Arg3, Arg4, Arg5, Arg6)> {
+
+  template<class T> struct sig { typedef Result type; };
+  template <class RET, class A1, class A2, class A3, class A4, class A5, class A6>
+  static Result apply(Result (*func)(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6), A1& a1, A2& a2, A3& a3, A4& a4, A5& a5, A6& a6) {
+    return func(a1, a2, a3, a4, a5, a6);
+  }
+};
+
+template <class Arg1, class Arg2, class Arg3, class Arg4, class Arg5, class Arg6, class Result>
+struct function_adaptor<Result (*)(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6)> {
+
+  template<class T> struct sig { typedef Result type; };
+  template <class RET, class A1, class A2, class A3, class A4, class A5, class A6>
+  static Result apply(Result (*func)(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6), A1& a1, A2& a2, A3& a3, A4& a4, A5& a5, A6& a6) {
+    return func(a1, a2, a3, a4, a5, a6);
+  }
+};
+
+
+// -- function adaptors with 8 argument apply
+template <class Object, class Arg1, class Arg2, class Arg3, class Arg4, class Arg5, class Arg6, class Result>
+struct function_adaptor<Result (Object::*)(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6) const> {
+
+  template<class T> struct sig { typedef Result type; };
+  template <class RET, class A1, class A2, class A3, class A4, class A5, class A6>
+  static Result apply( Result (Object::*func)(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6) const, const Object* o, A1& a1, A2& a2, A3& a3, A4& a4, A5& a5, A6& a6) {
+    return (o->*func)(a1, a2, a3, a4, a5, a6);
+  }
+  template <class RET, class A1, class A2, class A3, class A4, class A5, class A6>
+  static Result apply( Result (Object::*func)(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6) const, const Object& o, A1& a1, A2& a2, A3& a3, A4& a4, A5& a5, A6& a6) {
+    return (o.*func)(a1, a2, a3, a4, a5, a6);
+  }
+};
+
+template <class Object, class Arg1, class Arg2, class Arg3, class Arg4, class Arg5, class Arg6, class Result>
+struct function_adaptor<Result (Object::*)(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6)> {
+
+  template<class T> struct sig { typedef Result type; };
+  template <class RET, class A1, class A2, class A3, class A4, class A5, class A6>
+  static Result apply( Result (Object::*func)(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6), Object* o, A1& a1, A2& a2, A3& a3, A4& a4, A5& a5, A6& a6) {
+    return (o->*func)(a1, a2, a3, a4, a5, a6);
+  }
+  template <class RET, class A1, class A2, class A3, class A4, class A5, class A6>
+  static Result apply( Result (Object::*func)(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6), Object& o, A1& a1, A2& a2, A3& a3, A4& a4, A5& a5, A6& a6) {
+    return (o.*func)(a1, a2, a3, a4, a5, a6);
+  }
+};
+
+template <class Arg1, class Arg2, class Arg3, class Arg4, class Arg5, class Arg6, class Arg7, class Result>
+struct function_adaptor<Result (Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7)> {
+
+  template<class T> struct sig { typedef Result type; };
+  template <class RET, class A1, class A2, class A3, class A4, class A5, class A6, class A7>
+  static Result apply(Result (*func)(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7), A1& a1, A2& a2, A3& a3, A4& a4, A5& a5, A6& a6, A7& a7) {
+    return func(a1, a2, a3, a4, a5, a6, a7);
+  }
+};
+
+template <class Arg1, class Arg2, class Arg3, class Arg4, class Arg5, class Arg6, class Arg7, class Result>
+struct function_adaptor<Result (*)(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7)> {
+
+  template<class T> struct sig { typedef Result type; };
+  template <class RET, class A1, class A2, class A3, class A4, class A5, class A6, class A7>
+  static Result apply(Result (*func)(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7), A1& a1, A2& a2, A3& a3, A4& a4, A5& a5, A6& a6, A7& a7) {
+    return func(a1, a2, a3, a4, a5, a6, a7);
+  }
+};
+
+
+// -- function adaptors with 9 argument apply
+template <class Object, class Arg1, class Arg2, class Arg3, class Arg4, class Arg5, class Arg6, class Arg7, class Result>
+struct function_adaptor<Result (Object::*)(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7) const> {
+
+  template<class T> struct sig { typedef Result type; };
+  template <class RET, class A1, class A2, class A3, class A4, class A5, class A6, class A7>
+  static Result apply( Result (Object::*func)(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7) const, const Object* o, A1& a1, A2& a2, A3& a3, A4& a4, A5& a5, A6& a6, A7& a7) {
+    return (o->*func)(a1, a2, a3, a4, a5, a6, a7);
+  }
+  template <class RET, class A1, class A2, class A3, class A4, class A5, class A6, class A7>
+  static Result apply( Result (Object::*func)(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7) const, const Object& o, A1& a1, A2& a2, A3& a3, A4& a4, A5& a5, A6& a6, A7& a7) {
+    return (o.*func)(a1, a2, a3, a4, a5, a6, a7);
+  }
+};
+
+template <class Object, class Arg1, class Arg2, class Arg3, class Arg4, class Arg5, class Arg6, class Arg7, class Result>
+struct function_adaptor<Result (Object::*)(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7)> {
+
+  template<class T> struct sig { typedef Result type; };
+  template <class RET, class A1, class A2, class A3, class A4, class A5, class A6, class A7>
+  static Result apply( Result (Object::*func)(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7), Object* o, A1& a1, A2& a2, A3& a3, A4& a4, A5& a5, A6& a6, A7& a7) {
+    return (o->*func)(a1, a2, a3, a4, a5, a6, a7);
+  }
+  template <class RET, class A1, class A2, class A3, class A4, class A5, class A6, class A7>
+  static Result apply( Result (Object::*func)(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7), Object& o, A1& a1, A2& a2, A3& a3, A4& a4, A5& a5, A6& a6, A7& a7) {
+    return (o.*func)(a1, a2, a3, a4, a5, a6, a7);
+  }
+};
+
+template <class Arg1, class Arg2, class Arg3, class Arg4, class Arg5, class Arg6, class Arg7, class Arg8, class Result>
+struct function_adaptor<Result (Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7, Arg8)> {
+
+  template<class T> struct sig { typedef Result type; };
+  template <class RET, class A1, class A2, class A3, class A4, class A5, class A6, class A7, class A8>
+  static Result apply(Result (*func)(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7, Arg8), A1& a1, A2& a2, A3& a3, A4& a4, A5& a5, A6& a6, A7& a7, A8& a8) {
+    return func(a1, a2, a3, a4, a5, a6, a7, a8);
+  }
+};
+
+template <class Arg1, class Arg2, class Arg3, class Arg4, class Arg5, class Arg6, class Arg7, class Arg8, class Result>
+struct function_adaptor<Result (*)(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7, Arg8)> {
+
+  template<class T> struct sig { typedef Result type; };
+  template <class RET, class A1, class A2, class A3, class A4, class A5, class A6, class A7, class A8>
+  static Result apply(Result (*func)(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7, Arg8), A1& a1, A2& a2, A3& a3, A4& a4, A5& a5, A6& a6, A7& a7, A8& a8) {
+    return func(a1, a2, a3, a4, a5, a6, a7, a8);
+  }
+};
+
+
+// -- function adaptors with 10 argument apply
+template <class Object, class Arg1, class Arg2, class Arg3, class Arg4, class Arg5, class Arg6, class Arg7, class Arg8, class Result>
+struct function_adaptor<Result (Object::*)(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7, Arg8) const> {
+
+  template<class T> struct sig { typedef Result type; };
+  template <class RET, class A1, class A2, class A3, class A4, class A5, class A6, class A7, class A8>
+  static Result apply( Result (Object::*func)(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7, Arg8) const, const Object* o, A1& a1, A2& a2, A3& a3, A4& a4, A5& a5, A6& a6, A7& a7, A8& a8) {
+    return (o->*func)(a1, a2, a3, a4, a5, a6, a7, a8);
+  }
+  template <class RET, class A1, class A2, class A3, class A4, class A5, class A6, class A7, class A8>
+  static Result apply( Result (Object::*func)(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7, Arg8) const, const Object& o, A1& a1, A2& a2, A3& a3, A4& a4, A5& a5, A6& a6, A7& a7, A8& a8) {
+    return (o.*func)(a1, a2, a3, a4, a5, a6, a7, a8);
+  }
+};
+
+template <class Object, class Arg1, class Arg2, class Arg3, class Arg4, class Arg5, class Arg6, class Arg7, class Arg8, class Result>
+struct function_adaptor<Result (Object::*)(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7, Arg8)> {
+
+  template<class T> struct sig { typedef Result type; };
+  template <class RET, class A1, class A2, class A3, class A4, class A5, class A6, class A7, class A8>
+  static Result apply( Result (Object::*func)(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7, Arg8), Object* o, A1& a1, A2& a2, A3& a3, A4& a4, A5& a5, A6& a6, A7& a7, A8& a8) {
+    return (o->*func)(a1, a2, a3, a4, a5, a6, a7, a8);
+  }
+  template <class RET, class A1, class A2, class A3, class A4, class A5, class A6, class A7, class A8>
+  static Result apply( Result (Object::*func)(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7, Arg8), Object& o, A1& a1, A2& a2, A3& a3, A4& a4, A5& a5, A6& a6, A7& a7, A8& a8) {
+    return (o.*func)(a1, a2, a3, a4, a5, a6, a7, a8);
+  }
+};
+
+template <class Arg1, class Arg2, class Arg3, class Arg4, class Arg5, class Arg6, class Arg7, class Arg8, class Arg9, class Result>
+struct function_adaptor<Result (Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7, Arg8, Arg9)> {
+
+  template<class T> struct sig { typedef Result type; };
+  template <class RET, class A1, class A2, class A3, class A4, class A5, class A6, class A7, class A8, class A9>
+  static Result apply(Result (*func)(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7, Arg8, Arg9), A1& a1, A2& a2, A3& a3, A4& a4, A5& a5, A6& a6, A7& a7, A8& a8, A9& a9) {
+    return func(a1, a2, a3, a4, a5, a6, a7, a8, a9);
+  }
+};
+
+template <class Arg1, class Arg2, class Arg3, class Arg4, class Arg5, class Arg6, class Arg7, class Arg8, class Arg9, class Result>
+struct function_adaptor<Result (*)(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7, Arg8, Arg9)> {
+
+  template<class T> struct sig { typedef Result type; };
+  template <class RET, class A1, class A2, class A3, class A4, class A5, class A6, class A7, class A8, class A9>
+  static Result apply(Result (*func)(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7, Arg8, Arg9), A1& a1, A2& a2, A3& a3, A4& a4, A5& a5, A6& a6, A7& a7, A8& a8, A9& a9) {
+    return func(a1, a2, a3, a4, a5, a6, a7, a8, a9);
+  }
+};
+
+} // namespace lambda
+} // namespace ndnboost
+
+#endif
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/ndnboost/lambda/detail/is_instance_of.hpp b/ndnboost/lambda/detail/is_instance_of.hpp
new file mode 100644
index 0000000..3e91c66
--- /dev/null
+++ b/ndnboost/lambda/detail/is_instance_of.hpp
@@ -0,0 +1,104 @@
+// Boost Lambda Library - is_instance_of.hpp ---------------------
+
+// Copyright (C) 2001 Jaakko Jarvi (jaakko.jarvi@cs.utu.fi)
+//
+// Distributed under the Boost Software License, Version 1.0. (See
+// accompanying file LICENSE_1_0.txt or copy at
+// http://www.boost.org/LICENSE_1_0.txt)
+//
+// For more information, see www.boost.org
+
+// ---------------------------------------------------------------
+
+#ifndef BOOST_LAMBDA_IS_INSTANCE_OF
+#define BOOST_LAMBDA_IS_INSTANCE_OF
+
+#include "ndnboost/config.hpp" // for BOOST_STATIC_CONSTANT
+#include "ndnboost/type_traits/conversion_traits.hpp" // for is_convertible
+#include "ndnboost/preprocessor/enum_shifted_params.hpp"
+#include "ndnboost/preprocessor/repeat_2nd.hpp"
+
+// is_instance_of --------------------------------
+// 
+// is_instance_of_n<A, B>::value is true, if type A is 
+// an instantiation of a template B, or A derives from an instantiation 
+// of template B
+//
+// n is the number of template arguments for B
+// 
+// Example:
+// is_instance_of_2<std::istream, basic_stream>::value == true
+
+// The original implementation was somewhat different, with different versions
+// for different compilers. However, there was still a problem
+// with gcc.3.0.2 and 3.0.3 compilers, which didn't think regard
+// is_instance_of_N<...>::value was a constant.
+// John Maddock suggested the way around this problem by building 
+// is_instance_of templates using ndnboost::is_convertible.
+// Now we only have one version of is_instance_of templates, which delagate
+// all the nasty compiler tricks to is_convertible. 
+
+#define BOOST_LAMBDA_CLASS(z, N,A) BOOST_PP_COMMA_IF(N) class
+#define BOOST_LAMBDA_CLASS_ARG(z, N,A) BOOST_PP_COMMA_IF(N) class A##N 
+#define BOOST_LAMBDA_ARG(z, N,A) BOOST_PP_COMMA_IF(N) A##N 
+
+#define BOOST_LAMBDA_CLASS_LIST(n, NAME) BOOST_PP_REPEAT(n, BOOST_LAMBDA_CLASS, NAME)
+
+#define BOOST_LAMBDA_CLASS_ARG_LIST(n, NAME) BOOST_PP_REPEAT(n, BOOST_LAMBDA_CLASS_ARG, NAME)
+
+#define BOOST_LAMBDA_ARG_LIST(n, NAME) BOOST_PP_REPEAT(n, BOOST_LAMBDA_ARG, NAME)
+
+namespace ndnboost {
+namespace lambda {
+
+#define BOOST_LAMBDA_IS_INSTANCE_OF_TEMPLATE(INDEX)                         \
+                                                                            \
+namespace detail {                                                          \
+                                                                            \
+template <template<BOOST_LAMBDA_CLASS_LIST(INDEX,T)> class F>               \
+struct BOOST_PP_CAT(conversion_tester_,INDEX) {                             \
+  template<BOOST_LAMBDA_CLASS_ARG_LIST(INDEX,A)>                            \
+  BOOST_PP_CAT(conversion_tester_,INDEX)                                    \
+    (const F<BOOST_LAMBDA_ARG_LIST(INDEX,A)>&);                             \
+};                                                                          \
+                                                                            \
+} /* end detail */                                                          \
+                                                                            \
+template <class From, template <BOOST_LAMBDA_CLASS_LIST(INDEX,T)> class To> \
+struct BOOST_PP_CAT(is_instance_of_,INDEX)                                  \
+{                                                                           \
+ private:                                                                   \
+   typedef ::ndnboost::is_convertible<                                         \
+     From,                                                                  \
+     BOOST_PP_CAT(detail::conversion_tester_,INDEX)<To>                     \
+   > helper_type;                                                           \
+                                                                            \
+public:                                                                     \
+  BOOST_STATIC_CONSTANT(bool, value = helper_type::value);                  \
+};
+
+
+#define BOOST_LAMBDA_HELPER(z, N, A) BOOST_LAMBDA_IS_INSTANCE_OF_TEMPLATE( BOOST_PP_INC(N) )
+
+// Generate the traits for 1-4 argument templates
+
+BOOST_PP_REPEAT_2ND(4,BOOST_LAMBDA_HELPER,FOO)
+
+#undef BOOST_LAMBDA_HELPER
+#undef BOOST_LAMBDA_IS_INSTANCE_OF_TEMPLATE
+#undef BOOST_LAMBDA_CLASS
+#undef BOOST_LAMBDA_ARG
+#undef BOOST_LAMBDA_CLASS_ARG
+#undef BOOST_LAMBDA_CLASS_LIST
+#undef BOOST_LAMBDA_ARG_LIST
+#undef BOOST_LAMBDA_CLASS_ARG_LIST
+
+} // lambda
+} // boost
+
+#endif
+
+
+
+
+
diff --git a/ndnboost/lambda/detail/lambda_config.hpp b/ndnboost/lambda/detail/lambda_config.hpp
new file mode 100644
index 0000000..9fd1a7b
--- /dev/null
+++ b/ndnboost/lambda/detail/lambda_config.hpp
@@ -0,0 +1,48 @@
+// Boost Lambda Library - lambda_config.hpp ------------------------------
+
+// Copyright (C) 1999, 2000 Jaakko Jarvi (jaakko.jarvi@cs.utu.fi)
+//
+// Distributed under the Boost Software License, Version 1.0. (See
+// accompanying file LICENSE_1_0.txt or copy at
+// http://www.boost.org/LICENSE_1_0.txt)
+//
+// For more information, see www.boost.org
+
+// ---------------------------------------------------------------
+
+#ifndef BOOST_LAMBDA_LAMBDA_CONFIG_HPP
+#define BOOST_LAMBDA_LAMBDA_CONFIG_HPP
+
+// add to boost/config.hpp
+// for now
+
+
+# if defined __GNUC__
+#   if (__GNUC__ == 3 && __GNUC_MINOR__ >= 4) 
+#     define BOOST_REF_TO_FUNC_CONFLICTS_WITH_REF_TO_T
+#     define BOOST_LAMBDA_INCORRECT_BIND_OVERLOADING
+#   endif
+#   if (__GNUC__ == 2 && __GNUC_MINOR__ <= 97) 
+#     define BOOST_NO_TEMPLATED_STREAMS
+#     define BOOST_LAMBDA_INCORRECT_BIND_OVERLOADING
+#   endif
+#   if (__GNUC__ == 2 && __GNUC_MINOR__ <= 95) 
+#     define BOOST_LAMBDA_FAILS_IN_TEMPLATE_KEYWORD_AFTER_SCOPE_OPER
+#   endif
+# endif  // __GNUC__
+ 
+
+#if defined __KCC
+
+#define BOOST_NO_FDECL_TEMPLATES_AS_TEMPLATE_TEMPLATE_PARAMS
+
+#endif  // __KCC
+
+#endif
+
+
+
+
+
+
+
diff --git a/ndnboost/lambda/detail/lambda_functor_base.hpp b/ndnboost/lambda/detail/lambda_functor_base.hpp
new file mode 100644
index 0000000..2c90f56
--- /dev/null
+++ b/ndnboost/lambda/detail/lambda_functor_base.hpp
@@ -0,0 +1,615 @@
+// Boost Lambda Library  lambda_functor_base.hpp -----------------------------
+//
+// Copyright (C) 1999, 2000 Jaakko Jarvi (jaakko.jarvi@cs.utu.fi)
+//
+// Distributed under the Boost Software License, Version 1.0. (See
+// accompanying file LICENSE_1_0.txt or copy at
+// http://www.boost.org/LICENSE_1_0.txt)
+//
+// For more information, see www.boost.org
+
+// ------------------------------------------------------------
+
+#ifndef BOOST_LAMBDA_LAMBDA_FUNCTOR_BASE_HPP
+#define BOOST_LAMBDA_LAMBDA_FUNCTOR_BASE_HPP
+
+#include "ndnboost/type_traits/add_reference.hpp"
+#include "ndnboost/type_traits/add_const.hpp"
+#include "ndnboost/type_traits/remove_const.hpp"
+#include "ndnboost/lambda/detail/lambda_fwd.hpp"
+#include "ndnboost/lambda/detail/lambda_traits.hpp"
+
+namespace ndnboost { 
+namespace lambda {
+
+#if BOOST_WORKAROUND(BOOST_MSVC, >= 1400)
+#pragma warning(push)
+#pragma warning(disable:4512) //assignment operator could not be generated
+#endif
+
+  // for return type deductions we wrap bound argument to this class,
+  // which fulfils the base class contract for lambda_functors
+template <class T>
+class identity {
+
+  T elem;
+public:
+  
+  typedef T element_t;
+
+  // take all parameters as const references. Note that non-const references
+  // stay as they are.
+  typedef typename ndnboost::add_reference<
+    typename ndnboost::add_const<T>::type
+  >::type par_t;
+
+  explicit identity(par_t t) : elem(t) {}
+
+  template <typename SigArgs> 
+  struct sig { typedef typename ndnboost::remove_const<element_t>::type type; };
+
+  template<class RET, CALL_TEMPLATE_ARGS>
+  RET call(CALL_FORMAL_ARGS) const { CALL_USE_ARGS; return elem; }
+};
+
+#if BOOST_WORKAROUND(BOOST_MSVC, >= 1400)
+#pragma warning(pop)
+#endif
+
+template <class T> 
+inline lambda_functor<identity<T&> > var(T& t) { return identity<T&>(t); }
+
+  // for lambda functors, var is an identity operator. It was forbidden
+  // at some point, but we might want to var something that can be a 
+  // non-lambda functor or a lambda functor.
+template <class T>
+lambda_functor<T> var(const lambda_functor<T>& t) { return t; }
+
+template <class T> struct var_type {
+  typedef lambda_functor<identity<T&> > type;
+};
+
+
+template <class T> 
+inline 
+lambda_functor<identity<typename bound_argument_conversion<const T>::type> >
+constant(const T& t) { 
+  return identity<typename bound_argument_conversion<const T>::type>(t); 
+}
+template <class T>
+lambda_functor<T> constant(const lambda_functor<T>& t) { return t; }
+
+template <class T> struct constant_type {
+  typedef 
+   lambda_functor<
+     identity<typename bound_argument_conversion<const T>::type> 
+   > type;
+};
+
+
+
+template <class T> 
+inline lambda_functor<identity<const T&> > constant_ref(const T& t) { 
+  return identity<const T&>(t); 
+}
+template <class T>
+lambda_functor<T> constant_ref(const lambda_functor<T>& t) { return t; }
+
+template <class T> struct constant_ref_type {
+  typedef 
+   lambda_functor<identity<const T&> > type;
+};
+
+
+
+  // as_lambda_functor turns any types to lambda functors 
+  // non-lambda_functors will be bound argument types
+template <class T>
+struct as_lambda_functor { 
+  typedef typename 
+    detail::remove_reference_and_cv<T>::type plain_T;
+  typedef typename 
+    detail::IF<is_lambda_functor<plain_T>::value, 
+      plain_T,
+      lambda_functor<
+        identity<typename bound_argument_conversion<T>::type> 
+      >
+    >::RET type; 
+};
+
+// turns arbitrary objects into lambda functors
+template <class T> 
+inline 
+lambda_functor<identity<typename bound_argument_conversion<const T>::type> > 
+to_lambda_functor(const T& t) { 
+  return identity<typename bound_argument_conversion<const T>::type>(t);
+}
+
+template <class T> 
+inline lambda_functor<T> 
+to_lambda_functor(const lambda_functor<T>& t) { 
+  return t;
+}
+
+namespace detail {   
+
+
+
+// In a call constify_rvals<T>::go(x)
+// x should be of type T. If T is a non-reference type, do
+// returns x as const reference. 
+// Otherwise the type doesn't change.
+// The purpose of this class is to avoid 
+// 'cannot bind temporaries to non-const references' errors.
+template <class T> struct constify_rvals {
+  template<class U>
+  static inline const U& go(const U& u) { return u; }
+};
+
+template <class T> struct constify_rvals<T&> {
+  template<class U>
+  static inline U& go(U& u) { return u; }
+};
+
+  // check whether one of the elements of a tuple (cons list) is of type
+  // null_type. Needed, because the compiler goes ahead and instantiates
+  // sig template for nullary case even if the nullary operator() is not
+  // called
+template <class T> struct is_null_type 
+{ BOOST_STATIC_CONSTANT(bool, value = false); };
+
+template <> struct is_null_type<null_type> 
+{ BOOST_STATIC_CONSTANT(bool, value = true); };
+
+template<class Tuple> struct has_null_type {
+  BOOST_STATIC_CONSTANT(bool, value = (is_null_type<typename Tuple::head_type>::value || has_null_type<typename Tuple::tail_type>::value));
+};
+template<> struct has_null_type<null_type> {
+  BOOST_STATIC_CONSTANT(bool, value = false);
+};
+
+
+// helpers -------------------
+
+
+template<class Args, class SigArgs>
+class deduce_argument_types_ {
+  typedef typename as_lambda_functor<typename Args::head_type>::type lf_t;
+  typedef typename lf_t::inherited::template sig<SigArgs>::type el_t;  
+public:
+  typedef
+    ndnboost::tuples::cons<
+      el_t, 
+      typename deduce_argument_types_<typename Args::tail_type, SigArgs>::type
+    > type;
+};
+
+template<class SigArgs>
+class deduce_argument_types_<null_type, SigArgs> {
+public:
+  typedef null_type type; 
+};
+
+
+//  // note that tuples cannot have plain function types as elements.
+//  // Hence, all other types will be non-const, except references to 
+//  // functions.
+//  template <class T> struct remove_reference_except_from_functions {
+//    typedef typename ndnboost::remove_reference<T>::type t;
+//    typedef typename detail::IF<ndnboost::is_function<t>::value, T, t>::RET type;
+//  };
+
+template<class Args, class SigArgs>
+class deduce_non_ref_argument_types_ {
+  typedef typename as_lambda_functor<typename Args::head_type>::type lf_t;
+  typedef typename lf_t::inherited::template sig<SigArgs>::type el_t;  
+public:
+  typedef
+    ndnboost::tuples::cons<
+  //      typename detail::remove_reference_except_from_functions<el_t>::type, 
+      typename ndnboost::remove_reference<el_t>::type, 
+      typename deduce_non_ref_argument_types_<typename Args::tail_type, SigArgs>::type
+    > type;
+};
+
+template<class SigArgs>
+class deduce_non_ref_argument_types_<null_type, SigArgs> {
+public:
+  typedef null_type type; 
+};
+
+  // -------------
+
+// take stored Args and Open Args, and return a const list with 
+// deduced elements (real return types)
+template<class Args, class SigArgs>
+class deduce_argument_types {
+  typedef typename deduce_argument_types_<Args, SigArgs>::type t1;
+public:
+  typedef typename detail::IF<
+    has_null_type<t1>::value, null_type, t1
+  >::RET type; 
+};
+
+// take stored Args and Open Args, and return a const list with 
+// deduced elements (references are stripped from the element types)
+
+template<class Args, class SigArgs>
+class deduce_non_ref_argument_types {
+  typedef typename deduce_non_ref_argument_types_<Args, SigArgs>::type t1;
+public:
+  typedef typename detail::IF<
+    has_null_type<t1>::value, null_type, t1
+  >::RET type; 
+};
+
+template <int N, class Args, class SigArgs>
+struct nth_return_type_sig {
+  typedef typename 
+          as_lambda_functor<
+            typename ndnboost::tuples::element<N, Args>::type 
+  //            typename tuple_element_as_reference<N, Args>::type 
+        >::type lf_type;
+
+  typedef typename lf_type::inherited::template sig<SigArgs>::type type;  
+};
+
+template<int N, class Tuple> struct element_or_null {
+  typedef typename ndnboost::tuples::element<N, Tuple>::type type;
+};
+
+template<int N> struct element_or_null<N, null_type> {
+  typedef null_type type;
+};
+
+
+   
+   
+} // end detail
+   
+ // -- lambda_functor base ---------------------
+
+// the explicit_return_type_action case -----------------------------------
+template<class RET, class Args>
+class lambda_functor_base<explicit_return_type_action<RET>, Args> 
+{
+public:
+  Args args;
+
+  typedef RET result_type;
+
+  explicit lambda_functor_base(const Args& a) : args(a) {}
+
+  template <class SigArgs> struct sig { typedef RET type; };
+
+  template<class RET_, CALL_TEMPLATE_ARGS>
+  RET call(CALL_FORMAL_ARGS) const 
+  {
+    return detail::constify_rvals<RET>::go(
+     detail::r_select<RET>::go(ndnboost::tuples::get<0>(args), CALL_ACTUAL_ARGS));
+  }
+};
+
+// the protect_action case -----------------------------------
+template<class Args>
+class lambda_functor_base<protect_action, Args>
+{
+public:
+  Args args;
+public:
+
+  explicit lambda_functor_base(const Args& a) : args(a) {}
+
+
+  template<class RET, CALL_TEMPLATE_ARGS>
+  RET call(CALL_FORMAL_ARGS) const 
+  {
+     CALL_USE_ARGS;
+     return ndnboost::tuples::get<0>(args);
+  }
+
+  template<class SigArgs> struct sig { 
+    //    typedef typename detail::tuple_element_as_reference<0, SigArgs>::type type;
+    typedef typename ndnboost::tuples::element<0, Args>::type type;
+  };
+};
+
+// Do nothing --------------------------------------------------------
+class do_nothing_action {};
+
+template<class Args>
+class lambda_functor_base<do_nothing_action, Args> {
+  //  Args args;
+public:
+  //  explicit lambda_functor_base(const Args& a) {}
+  lambda_functor_base() {}
+
+
+  template<class RET, CALL_TEMPLATE_ARGS> RET call(CALL_FORMAL_ARGS) const {
+    return CALL_USE_ARGS;
+  }
+
+  template<class SigArgs> struct sig { typedef void type; };
+};  
+
+
+//  These specializations provide a shorter notation to define actions.
+//  These lambda_functor_base instances take care of the recursive evaluation
+//  of the arguments and pass the evaluated arguments to the apply function
+//  of an action class. To make action X work with these classes, one must
+//  instantiate the lambda_functor_base as:
+//  lambda_functor_base<action<ARITY, X>, Args>
+//  Where ARITY is the arity of the apply function in X
+
+//  The return type is queried as:
+//  return_type_N<X, EvaluatedArgumentTypes>::type
+//  for which there must be a specialization.
+
+//  Function actions, casts, throws,... all go via these classes.
+
+
+template<class Act, class Args>  
+class lambda_functor_base<action<0, Act>, Args>           
+{  
+public:  
+//  Args args; not needed
+  explicit lambda_functor_base(const Args& /*a*/) {}  
+  
+  template<class SigArgs> struct sig {  
+    typedef typename return_type_N<Act, null_type>::type type;
+  };
+  
+  template<class RET, CALL_TEMPLATE_ARGS>  
+  RET call(CALL_FORMAL_ARGS) const {  
+    CALL_USE_ARGS;
+    return Act::template apply<RET>();
+  }
+};
+
+
+#if defined BOOST_LAMBDA_LAMBDA_FUNCTOR_BASE_FIRST_PART  
+#error "Multiple defines of BOOST_LAMBDA_LAMBDA_FUNCTOR_BASE_FIRST_PART"  
+#endif  
+  
+  
+#define BOOST_LAMBDA_LAMBDA_FUNCTOR_BASE_FIRST_PART(ARITY)             \
+template<class Act, class Args>                                        \
+class lambda_functor_base<action<ARITY, Act>, Args>                    \
+{                                                                      \
+public:                                                                \
+  Args args;                                                           \
+                                                                       \
+  explicit lambda_functor_base(const Args& a) : args(a) {}             \
+                                                                       \
+  template<class SigArgs> struct sig {                                 \
+    typedef typename                                                   \
+    detail::deduce_argument_types<Args, SigArgs>::type rets_t;         \
+  public:                                                              \
+    typedef typename                                                   \
+      return_type_N_prot<Act, rets_t>::type type;                      \
+  };                                                                   \
+                                                                       \
+                                                                       \
+  template<class RET, CALL_TEMPLATE_ARGS>                              \
+  RET call(CALL_FORMAL_ARGS) const {                                   \
+    using ndnboost::tuples::get;                                          \
+    using detail::constify_rvals;                                      \
+    using detail::r_select;                                            \
+    using detail::element_or_null;                                     \
+    using detail::deduce_argument_types;                                
+
+BOOST_LAMBDA_LAMBDA_FUNCTOR_BASE_FIRST_PART(1)
+
+  typedef typename
+    deduce_argument_types<Args, tuple<CALL_REFERENCE_TYPES> >::type rets_t;
+  typedef typename element_or_null<0, rets_t>::type rt0;
+
+  return Act::template apply<RET>(
+    constify_rvals<rt0>::go(r_select<rt0>::go(get<0>(args), CALL_ACTUAL_ARGS))
+    );
+  }
+};
+
+
+BOOST_LAMBDA_LAMBDA_FUNCTOR_BASE_FIRST_PART(2)
+  
+  typedef typename 
+    deduce_argument_types<Args, tuple<CALL_REFERENCE_TYPES> >::type rets_t;
+  typedef typename element_or_null<0, rets_t>::type rt0;
+  typedef typename element_or_null<1, rets_t>::type rt1;
+
+  return Act::template apply<RET>(
+    constify_rvals<rt0>::go(r_select<rt0>::go(get<0>(args), CALL_ACTUAL_ARGS)),
+    constify_rvals<rt1>::go(r_select<rt1>::go(get<1>(args), CALL_ACTUAL_ARGS))
+    );
+  }
+};
+
+BOOST_LAMBDA_LAMBDA_FUNCTOR_BASE_FIRST_PART(3)
+
+  typedef typename 
+    deduce_argument_types<Args, tuple<CALL_REFERENCE_TYPES> >::type rets_t;
+
+  typedef typename element_or_null<0, rets_t>::type rt0;
+  typedef typename element_or_null<1, rets_t>::type rt1;
+  typedef typename element_or_null<2, rets_t>::type rt2;
+
+  return Act::template apply<RET>(
+    constify_rvals<rt0>::go(r_select<rt0>::go(get<0>(args), CALL_ACTUAL_ARGS)),
+    constify_rvals<rt1>::go(r_select<rt1>::go(get<1>(args), CALL_ACTUAL_ARGS)),
+    constify_rvals<rt2>::go(r_select<rt2>::go(get<2>(args), CALL_ACTUAL_ARGS))
+    );
+  }
+};
+
+BOOST_LAMBDA_LAMBDA_FUNCTOR_BASE_FIRST_PART(4)
+  typedef typename 
+    deduce_argument_types<Args, tuple<CALL_REFERENCE_TYPES> >::type rets_t;
+  typedef typename element_or_null<0, rets_t>::type rt0;
+  typedef typename element_or_null<1, rets_t>::type rt1;
+  typedef typename element_or_null<2, rets_t>::type rt2;
+  typedef typename element_or_null<3, rets_t>::type rt3;
+
+  return Act::template apply<RET>(
+    constify_rvals<rt0>::go(r_select<rt0>::go(get<0>(args), CALL_ACTUAL_ARGS)),
+    constify_rvals<rt1>::go(r_select<rt1>::go(get<1>(args), CALL_ACTUAL_ARGS)),
+    constify_rvals<rt2>::go(r_select<rt2>::go(get<2>(args), CALL_ACTUAL_ARGS)),
+    constify_rvals<rt3>::go(r_select<rt3>::go(get<3>(args), CALL_ACTUAL_ARGS))
+    );
+  }
+};
+
+BOOST_LAMBDA_LAMBDA_FUNCTOR_BASE_FIRST_PART(5)
+  typedef typename 
+    deduce_argument_types<Args, tuple<CALL_REFERENCE_TYPES> >::type rets_t;
+  typedef typename element_or_null<0, rets_t>::type rt0;
+  typedef typename element_or_null<1, rets_t>::type rt1;
+  typedef typename element_or_null<2, rets_t>::type rt2;
+  typedef typename element_or_null<3, rets_t>::type rt3;
+  typedef typename element_or_null<4, rets_t>::type rt4;
+
+  return Act::template apply<RET>(
+    constify_rvals<rt0>::go(r_select<rt0>::go(get<0>(args), CALL_ACTUAL_ARGS)),
+    constify_rvals<rt1>::go(r_select<rt1>::go(get<1>(args), CALL_ACTUAL_ARGS)),
+    constify_rvals<rt2>::go(r_select<rt2>::go(get<2>(args), CALL_ACTUAL_ARGS)),
+    constify_rvals<rt3>::go(r_select<rt3>::go(get<3>(args), CALL_ACTUAL_ARGS)),
+    constify_rvals<rt4>::go(r_select<rt4>::go(get<4>(args), CALL_ACTUAL_ARGS))
+    );
+  }
+};
+
+BOOST_LAMBDA_LAMBDA_FUNCTOR_BASE_FIRST_PART(6)
+
+  typedef typename 
+    deduce_argument_types<Args, tuple<CALL_REFERENCE_TYPES> >::type rets_t;
+  typedef typename element_or_null<0, rets_t>::type rt0;
+  typedef typename element_or_null<1, rets_t>::type rt1;
+  typedef typename element_or_null<2, rets_t>::type rt2;
+  typedef typename element_or_null<3, rets_t>::type rt3;
+  typedef typename element_or_null<4, rets_t>::type rt4;
+  typedef typename element_or_null<5, rets_t>::type rt5;
+
+
+    return Act::template apply<RET>(
+    constify_rvals<rt0>::go(r_select<rt0>::go(get<0>(args), CALL_ACTUAL_ARGS)),
+    constify_rvals<rt1>::go(r_select<rt1>::go(get<1>(args), CALL_ACTUAL_ARGS)),
+    constify_rvals<rt2>::go(r_select<rt2>::go(get<2>(args), CALL_ACTUAL_ARGS)),
+    constify_rvals<rt3>::go(r_select<rt3>::go(get<3>(args), CALL_ACTUAL_ARGS)),
+    constify_rvals<rt4>::go(r_select<rt4>::go(get<4>(args), CALL_ACTUAL_ARGS)),
+    constify_rvals<rt5>::go(r_select<rt5>::go(get<5>(args), CALL_ACTUAL_ARGS)) 
+    );
+  }
+};
+
+BOOST_LAMBDA_LAMBDA_FUNCTOR_BASE_FIRST_PART(7)
+  typedef typename 
+    deduce_argument_types<Args, tuple<CALL_REFERENCE_TYPES> >::type rets_t;
+  typedef typename element_or_null<0, rets_t>::type rt0;
+  typedef typename element_or_null<1, rets_t>::type rt1;
+  typedef typename element_or_null<2, rets_t>::type rt2;
+  typedef typename element_or_null<3, rets_t>::type rt3;
+  typedef typename element_or_null<4, rets_t>::type rt4;
+  typedef typename element_or_null<5, rets_t>::type rt5;
+  typedef typename element_or_null<6, rets_t>::type rt6;
+
+
+  return Act::template apply<RET>(
+    constify_rvals<rt0>::go(r_select<rt0>::go(get<0>(args), CALL_ACTUAL_ARGS)),
+    constify_rvals<rt1>::go(r_select<rt1>::go(get<1>(args), CALL_ACTUAL_ARGS)),
+    constify_rvals<rt2>::go(r_select<rt2>::go(get<2>(args), CALL_ACTUAL_ARGS)),
+    constify_rvals<rt3>::go(r_select<rt3>::go(get<3>(args), CALL_ACTUAL_ARGS)),
+    constify_rvals<rt4>::go(r_select<rt4>::go(get<4>(args), CALL_ACTUAL_ARGS)),
+    constify_rvals<rt5>::go(r_select<rt5>::go(get<5>(args), CALL_ACTUAL_ARGS)),
+    constify_rvals<rt6>::go(r_select<rt6>::go(get<6>(args), CALL_ACTUAL_ARGS))
+    );
+  }
+};
+
+BOOST_LAMBDA_LAMBDA_FUNCTOR_BASE_FIRST_PART(8)
+  typedef typename 
+    deduce_argument_types<Args, tuple<CALL_REFERENCE_TYPES> >::type rets_t;
+  typedef typename element_or_null<0, rets_t>::type rt0;
+  typedef typename element_or_null<1, rets_t>::type rt1;
+  typedef typename element_or_null<2, rets_t>::type rt2;
+  typedef typename element_or_null<3, rets_t>::type rt3;
+  typedef typename element_or_null<4, rets_t>::type rt4;
+  typedef typename element_or_null<5, rets_t>::type rt5;
+  typedef typename element_or_null<6, rets_t>::type rt6;
+  typedef typename element_or_null<7, rets_t>::type rt7;
+
+  return Act::template apply<RET>(
+    constify_rvals<rt0>::go(r_select<rt0>::go(get<0>(args), CALL_ACTUAL_ARGS)),
+    constify_rvals<rt1>::go(r_select<rt1>::go(get<1>(args), CALL_ACTUAL_ARGS)),
+    constify_rvals<rt2>::go(r_select<rt2>::go(get<2>(args), CALL_ACTUAL_ARGS)),
+    constify_rvals<rt3>::go(r_select<rt3>::go(get<3>(args), CALL_ACTUAL_ARGS)),
+    constify_rvals<rt4>::go(r_select<rt4>::go(get<4>(args), CALL_ACTUAL_ARGS)),
+    constify_rvals<rt5>::go(r_select<rt5>::go(get<5>(args), CALL_ACTUAL_ARGS)),
+    constify_rvals<rt6>::go(r_select<rt6>::go(get<6>(args), CALL_ACTUAL_ARGS)),
+    constify_rvals<rt7>::go(r_select<rt7>::go(get<7>(args), CALL_ACTUAL_ARGS))
+    );
+  }
+};
+
+BOOST_LAMBDA_LAMBDA_FUNCTOR_BASE_FIRST_PART(9)
+  typedef typename 
+    deduce_argument_types<Args, tuple<CALL_REFERENCE_TYPES> >::type rets_t;
+  typedef typename element_or_null<0, rets_t>::type rt0;
+  typedef typename element_or_null<1, rets_t>::type rt1;
+  typedef typename element_or_null<2, rets_t>::type rt2;
+  typedef typename element_or_null<3, rets_t>::type rt3;
+  typedef typename element_or_null<4, rets_t>::type rt4;
+  typedef typename element_or_null<5, rets_t>::type rt5;
+  typedef typename element_or_null<6, rets_t>::type rt6;
+  typedef typename element_or_null<7, rets_t>::type rt7;
+  typedef typename element_or_null<8, rets_t>::type rt8;
+
+  return Act::template apply<RET>(
+    constify_rvals<rt0>::go(r_select<rt0>::go(get<0>(args), CALL_ACTUAL_ARGS)),
+    constify_rvals<rt1>::go(r_select<rt1>::go(get<1>(args), CALL_ACTUAL_ARGS)),
+    constify_rvals<rt2>::go(r_select<rt2>::go(get<2>(args), CALL_ACTUAL_ARGS)),
+    constify_rvals<rt3>::go(r_select<rt3>::go(get<3>(args), CALL_ACTUAL_ARGS)),
+    constify_rvals<rt4>::go(r_select<rt4>::go(get<4>(args), CALL_ACTUAL_ARGS)),
+    constify_rvals<rt5>::go(r_select<rt5>::go(get<5>(args), CALL_ACTUAL_ARGS)),
+    constify_rvals<rt6>::go(r_select<rt6>::go(get<6>(args), CALL_ACTUAL_ARGS)),
+    constify_rvals<rt7>::go(r_select<rt7>::go(get<7>(args), CALL_ACTUAL_ARGS)),
+    constify_rvals<rt8>::go(r_select<rt8>::go(get<8>(args), CALL_ACTUAL_ARGS))
+    );
+  }
+};
+
+BOOST_LAMBDA_LAMBDA_FUNCTOR_BASE_FIRST_PART(10) 
+  typedef typename 
+    deduce_argument_types<Args, tuple<CALL_REFERENCE_TYPES> >::type rets_t;
+  typedef typename element_or_null<0, rets_t>::type rt0;
+  typedef typename element_or_null<1, rets_t>::type rt1;
+  typedef typename element_or_null<2, rets_t>::type rt2;
+  typedef typename element_or_null<3, rets_t>::type rt3;
+  typedef typename element_or_null<4, rets_t>::type rt4;
+  typedef typename element_or_null<5, rets_t>::type rt5;
+  typedef typename element_or_null<6, rets_t>::type rt6;
+  typedef typename element_or_null<7, rets_t>::type rt7;
+  typedef typename element_or_null<8, rets_t>::type rt8;
+  typedef typename element_or_null<9, rets_t>::type rt9;
+
+  return Act::template apply<RET>(
+    constify_rvals<rt0>::go(r_select<rt0>::go(get<0>(args), CALL_ACTUAL_ARGS)),
+    constify_rvals<rt1>::go(r_select<rt1>::go(get<1>(args), CALL_ACTUAL_ARGS)),
+    constify_rvals<rt2>::go(r_select<rt2>::go(get<2>(args), CALL_ACTUAL_ARGS)),
+    constify_rvals<rt3>::go(r_select<rt3>::go(get<3>(args), CALL_ACTUAL_ARGS)),
+    constify_rvals<rt4>::go(r_select<rt4>::go(get<4>(args), CALL_ACTUAL_ARGS)),
+    constify_rvals<rt5>::go(r_select<rt5>::go(get<5>(args), CALL_ACTUAL_ARGS)),
+    constify_rvals<rt6>::go(r_select<rt6>::go(get<6>(args), CALL_ACTUAL_ARGS)),
+    constify_rvals<rt7>::go(r_select<rt7>::go(get<7>(args), CALL_ACTUAL_ARGS)),
+    constify_rvals<rt8>::go(r_select<rt8>::go(get<8>(args), CALL_ACTUAL_ARGS)),
+    constify_rvals<rt9>::go(r_select<rt9>::go(get<9>(args), CALL_ACTUAL_ARGS)) 
+    );
+  }
+};
+
+#undef BOOST_LAMBDA_LAMBDA_FUNCTOR_BASE_FIRST_PART
+
+
+} // namespace lambda
+} // namespace ndnboost
+
+#endif
diff --git a/ndnboost/lambda/detail/lambda_functors.hpp b/ndnboost/lambda/detail/lambda_functors.hpp
new file mode 100644
index 0000000..a6a9a7c
--- /dev/null
+++ b/ndnboost/lambda/detail/lambda_functors.hpp
@@ -0,0 +1,357 @@
+// Boost Lambda Library -  lambda_functors.hpp -------------------------------
+
+// Copyright (C) 1999, 2000 Jaakko Jarvi (jaakko.jarvi@cs.utu.fi)
+//
+// Distributed under the Boost Software License, Version 1.0. (See
+// accompanying file LICENSE_1_0.txt or copy at
+// http://www.boost.org/LICENSE_1_0.txt)
+//
+// For more information, see http://www.boost.org
+
+// ------------------------------------------------
+
+#ifndef BOOST_LAMBDA_LAMBDA_FUNCTORS_HPP
+#define BOOST_LAMBDA_LAMBDA_FUNCTORS_HPP
+
+#include <ndnboost/config.hpp>
+#include <ndnboost/detail/workaround.hpp>
+#include <ndnboost/utility/result_of.hpp>
+
+#if BOOST_WORKAROUND(BOOST_MSVC, == 1310)
+
+#include <ndnboost/mpl/or.hpp>
+#include <ndnboost/utility/enable_if.hpp>
+#include <ndnboost/type_traits/is_array.hpp>
+
+#define BOOST_LAMBDA_DISABLE_IF_ARRAY1(A1, R1)\
+  typename lazy_disable_if<is_array<A1>, typename R1 >::type
+#define BOOST_LAMBDA_DISABLE_IF_ARRAY2(A1, A2, R1, R2) \
+  typename lazy_disable_if<mpl::or_<is_array<A1>, is_array<A2> >, typename R1, R2 >::type
+#define BOOST_LAMBDA_DISABLE_IF_ARRAY3(A1, A2, A3, R1, R2, R3) \
+  typename lazy_disable_if<mpl::or_<is_array<A1>, is_array<A2>, is_array<A3> >, typename R1, R2, R3 >::type
+
+#else
+
+#define BOOST_LAMBDA_DISABLE_IF_ARRAY1(A1, R1) typename R1::type
+#define BOOST_LAMBDA_DISABLE_IF_ARRAY2(A1, A2, R1, R2) typename R1, R2::type
+#define BOOST_LAMBDA_DISABLE_IF_ARRAY3(A1, A2, A3, R1, R2, R3) typename R1, R2, R3::type
+
+#endif
+
+namespace ndnboost { 
+namespace lambda {
+
+// -- lambda_functor --------------------------------------------
+// --------------------------------------------------------------
+
+//inline const null_type const_null_type() { return null_type(); }
+
+namespace detail {
+namespace {
+
+  static const null_type constant_null_type = null_type();
+
+} // unnamed
+} // detail
+
+class unused {};
+
+#define cnull_type() detail::constant_null_type
+
+// -- free variables types -------------------------------------------------- 
+ 
+  // helper to work around the case where the nullary return type deduction 
+  // is always performed, even though the functor is not nullary  
+namespace detail {
+  template<int N, class Tuple> struct get_element_or_null_type {
+    typedef typename 
+      detail::tuple_element_as_reference<N, Tuple>::type type;
+  };
+  template<int N> struct get_element_or_null_type<N, null_type> {
+    typedef null_type type;
+  };
+}
+
+template <int I> struct placeholder;
+
+template<> struct placeholder<FIRST> {
+
+  template<class SigArgs> struct sig {
+    typedef typename detail::get_element_or_null_type<0, SigArgs>::type type;
+  };
+
+  template<class RET, CALL_TEMPLATE_ARGS> 
+  RET call(CALL_FORMAL_ARGS) const { 
+    BOOST_STATIC_ASSERT(ndnboost::is_reference<RET>::value); 
+    CALL_USE_ARGS; // does nothing, prevents warnings for unused args
+    return a; 
+  }
+};
+
+template<> struct placeholder<SECOND> {
+
+  template<class SigArgs> struct sig {
+    typedef typename detail::get_element_or_null_type<1, SigArgs>::type type;
+  };
+
+  template<class RET, CALL_TEMPLATE_ARGS> 
+  RET call(CALL_FORMAL_ARGS) const { CALL_USE_ARGS; return b; }
+};
+
+template<> struct placeholder<THIRD> {
+
+  template<class SigArgs> struct sig {
+    typedef typename detail::get_element_or_null_type<2, SigArgs>::type type;
+  };
+
+  template<class RET, CALL_TEMPLATE_ARGS> 
+  RET call(CALL_FORMAL_ARGS) const { CALL_USE_ARGS; return c; }
+};
+
+template<> struct placeholder<EXCEPTION> {
+
+  template<class SigArgs> struct sig {
+    typedef typename detail::get_element_or_null_type<3, SigArgs>::type type;
+  };
+
+  template<class RET, CALL_TEMPLATE_ARGS> 
+  RET call(CALL_FORMAL_ARGS) const { CALL_USE_ARGS; return env; }
+};
+   
+typedef const lambda_functor<placeholder<FIRST> >  placeholder1_type;
+typedef const lambda_functor<placeholder<SECOND> > placeholder2_type;
+typedef const lambda_functor<placeholder<THIRD> >  placeholder3_type;
+   
+
+///////////////////////////////////////////////////////////////////////////////
+
+
+// free variables are lambda_functors. This is to allow uniform handling with 
+// other lambda_functors.
+// -------------------------------------------------------------------
+
+#if BOOST_WORKAROUND(BOOST_MSVC, >= 1400)
+#pragma warning(push)
+#pragma warning(disable:4512) //assignment operator could not be generated
+#endif
+
+// -- lambda_functor NONE ------------------------------------------------
+template <class T>
+class lambda_functor : public T 
+{
+
+BOOST_STATIC_CONSTANT(int, arity_bits = get_arity<T>::value);
+ 
+public:
+  typedef T inherited;
+
+  lambda_functor() {}
+  lambda_functor(const lambda_functor& l) : inherited(l) {}
+
+  lambda_functor(const T& t) : inherited(t) {}
+
+  template <class SigArgs> struct sig {
+    typedef typename inherited::template 
+      sig<typename SigArgs::tail_type>::type type;
+  };
+
+  // Note that this return type deduction template is instantiated, even 
+  // if the nullary 
+  // operator() is not called at all. One must make sure that it does not fail.
+  typedef typename 
+    inherited::template sig<null_type>::type
+      nullary_return_type;
+
+  // Support for ndnboost::result_of.
+  template <class Sig> struct result;
+  template <class F>
+  struct result<F()> {
+    typedef nullary_return_type type;
+  };
+  template <class F, class A>
+  struct result<F(A)> {
+    typedef typename sig<tuple<F, A> >::type type;
+  };
+  template <class F, class A, class B>
+  struct result<F(A, B)> {
+    typedef typename sig<tuple<F, A, B> >::type type;
+  };
+  template <class F, class A, class B, class C>
+  struct result<F(A, B, C)> {
+    typedef typename sig<tuple<F, A, B, C> >::type type;
+  };
+
+  nullary_return_type operator()() const { 
+    return inherited::template 
+      call<nullary_return_type>
+        (cnull_type(), cnull_type(), cnull_type(), cnull_type()); 
+  }
+
+  template<class A>
+  typename inherited::template sig<tuple<A&> >::type
+  operator()(A& a) const { 
+    return inherited::template call<
+      typename inherited::template sig<tuple<A&> >::type
+    >(a, cnull_type(), cnull_type(), cnull_type());
+  }
+
+  template<class A>
+  BOOST_LAMBDA_DISABLE_IF_ARRAY1(A, inherited::template sig<tuple<A const&> >)
+  operator()(A const& a) const { 
+    return inherited::template call<
+      typename inherited::template sig<tuple<A const&> >::type
+    >(a, cnull_type(), cnull_type(), cnull_type());
+  }
+
+  template<class A, class B>
+  typename inherited::template sig<tuple<A&, B&> >::type
+  operator()(A& a, B& b) const { 
+    return inherited::template call<
+      typename inherited::template sig<tuple<A&, B&> >::type
+    >(a, b, cnull_type(), cnull_type()); 
+  }
+
+  template<class A, class B>
+  BOOST_LAMBDA_DISABLE_IF_ARRAY2(A, B, inherited::template sig<tuple<A const&, B&> >)
+  operator()(A const& a, B& b) const { 
+    return inherited::template call<
+      typename inherited::template sig<tuple<A const&, B&> >::type
+    >(a, b, cnull_type(), cnull_type()); 
+  }
+
+  template<class A, class B>
+  BOOST_LAMBDA_DISABLE_IF_ARRAY2(A, B, inherited::template sig<tuple<A&, B const&> >)
+  operator()(A& a, B const& b) const { 
+    return inherited::template call<
+      typename inherited::template sig<tuple<A&, B const&> >::type
+    >(a, b, cnull_type(), cnull_type()); 
+  }
+
+  template<class A, class B>
+  BOOST_LAMBDA_DISABLE_IF_ARRAY2(A, B, inherited::template sig<tuple<A const&, B const&> >)
+  operator()(A const& a, B const& b) const { 
+    return inherited::template call<
+      typename inherited::template sig<tuple<A const&, B const&> >::type
+    >(a, b, cnull_type(), cnull_type()); 
+  }
+
+  template<class A, class B, class C>
+  typename inherited::template sig<tuple<A&, B&, C&> >::type
+  operator()(A& a, B& b, C& c) const
+  { 
+    return inherited::template call<
+      typename inherited::template sig<tuple<A&, B&, C&> >::type
+    >(a, b, c, cnull_type()); 
+  }
+
+  template<class A, class B, class C>
+  BOOST_LAMBDA_DISABLE_IF_ARRAY3(A, B, C, inherited::template sig<tuple<A const&, B const&, C const&> >)
+  operator()(A const& a, B const& b, C const& c) const
+  { 
+    return inherited::template call<
+      typename inherited::template sig<tuple<A const&, B const&, C const&> >::type
+    >(a, b, c, cnull_type()); 
+  }
+
+  // for internal calls with env
+  template<CALL_TEMPLATE_ARGS>
+  typename inherited::template sig<tuple<CALL_REFERENCE_TYPES> >::type
+  internal_call(CALL_FORMAL_ARGS) const { 
+     return inherited::template 
+       call<typename inherited::template 
+         sig<tuple<CALL_REFERENCE_TYPES> >::type>(CALL_ACTUAL_ARGS); 
+  }
+
+  template<class A>
+  const lambda_functor<lambda_functor_base<
+                  other_action<assignment_action>,
+                  ndnboost::tuple<lambda_functor,
+                  typename const_copy_argument <const A>::type> > >
+  operator=(const A& a) const {
+    return lambda_functor_base<
+                  other_action<assignment_action>,
+                  ndnboost::tuple<lambda_functor,
+                  typename const_copy_argument <const A>::type> >
+     (  ndnboost::tuple<lambda_functor,
+             typename const_copy_argument <const A>::type>(*this, a) );
+  }
+
+  template<class A> 
+  const lambda_functor<lambda_functor_base< 
+                  other_action<subscript_action>, 
+                  ndnboost::tuple<lambda_functor, 
+                        typename const_copy_argument <const A>::type> > > 
+  operator[](const A& a) const { 
+    return lambda_functor_base< 
+                  other_action<subscript_action>, 
+                  ndnboost::tuple<lambda_functor, 
+                        typename const_copy_argument <const A>::type> >
+     ( ndnboost::tuple<lambda_functor, 
+             typename const_copy_argument <const A>::type>(*this, a ) ); 
+  } 
+};
+
+#if BOOST_WORKAROUND(BOOST_MSVC, >= 1400)
+#pragma warning(pop)
+#endif
+
+} // namespace lambda
+} // namespace ndnboost
+
+namespace ndnboost {
+
+#if !defined(BOOST_RESULT_OF_USE_DECLTYPE) || defined(BOOST_NO_DECLTYPE)
+
+template<class T>
+struct result_of<ndnboost::lambda::lambda_functor<T>()>
+{
+    typedef typename ndnboost::lambda::lambda_functor<T>::nullary_return_type type;
+};
+
+template<class T>
+struct result_of<const ndnboost::lambda::lambda_functor<T>()>
+{
+    typedef typename ndnboost::lambda::lambda_functor<T>::nullary_return_type type;
+};
+
+#endif
+
+template<class T>
+struct tr1_result_of<ndnboost::lambda::lambda_functor<T>()>
+{
+    typedef typename ndnboost::lambda::lambda_functor<T>::nullary_return_type type;
+};
+
+template<class T>
+struct tr1_result_of<const ndnboost::lambda::lambda_functor<T>()>
+{
+    typedef typename ndnboost::lambda::lambda_functor<T>::nullary_return_type type;
+};
+
+}
+
+// is_placeholder
+
+#include <ndnboost/is_placeholder.hpp>
+
+namespace ndnboost
+{
+
+template<> struct is_placeholder< lambda::lambda_functor< lambda::placeholder<lambda::FIRST> > >
+{
+    enum _vt { value = 1 };
+};
+
+template<> struct is_placeholder< lambda::lambda_functor< lambda::placeholder<lambda::SECOND> > >
+{
+    enum _vt { value = 2 };
+};
+
+template<> struct is_placeholder< lambda::lambda_functor< lambda::placeholder<lambda::THIRD> > >
+{
+    enum _vt { value = 3 };
+};
+
+} // namespace ndnboost
+
+#endif
diff --git a/ndnboost/lambda/detail/lambda_fwd.hpp b/ndnboost/lambda/detail/lambda_fwd.hpp
new file mode 100644
index 0000000..e0253b7
--- /dev/null
+++ b/ndnboost/lambda/detail/lambda_fwd.hpp
@@ -0,0 +1,74 @@
+//  lambda_fwd.hpp - Boost Lambda Library -------------------------------
+
+// Copyright (C) 1999, 2000 Jaakko Jarvi (jaakko.jarvi@cs.utu.fi)
+//
+// Distributed under the Boost Software License, Version 1.0. (See
+// accompanying file LICENSE_1_0.txt or copy at
+// http://www.boost.org/LICENSE_1_0.txt)
+//
+// For more information, see www.boost.org
+
+// -------------------------------------------------------
+
+#ifndef BOOST_LAMBDA_FWD_HPP
+#define BOOST_LAMBDA_FWD_HPP
+
+namespace ndnboost { 
+namespace lambda { 
+
+namespace detail {
+
+template<class T> struct generate_error;
+
+}   
+// -- placeholders --------------------------------------------
+
+template <int I> struct placeholder;
+
+// function_adaptors
+template <class Func> 
+struct function_adaptor;
+
+template <int I, class Act> class action;
+
+template <class Base> 
+class lambda_functor;
+
+template <class Act, class Args> 
+class lambda_functor_base;
+
+} // namespace lambda
+} // namespace ndnboost
+
+
+//  #define CALL_TEMPLATE_ARGS class A, class Env
+//  #define CALL_FORMAL_ARGS A& a, Env& env
+//  #define CALL_ACTUAL_ARGS a, env
+//  #define CALL_ACTUAL_ARGS_NO_ENV a
+//  #define CALL_REFERENCE_TYPES A&, Env&
+//  #define CALL_PLAIN_TYPES A, Env
+#define CALL_TEMPLATE_ARGS class A, class B, class C, class Env
+#define CALL_FORMAL_ARGS A& a, B& b, C& c, Env& env
+#define CALL_ACTUAL_ARGS a, b, c, env
+#define CALL_ACTUAL_ARGS_NO_ENV a, b, c
+#define CALL_REFERENCE_TYPES A&, B&, C&, Env&
+#define CALL_PLAIN_TYPES A, B, C, Env
+
+namespace ndnboost {
+namespace lambda {
+namespace detail {
+
+template<class A1, class A2, class A3, class A4>
+void do_nothing(A1&, A2&, A3&, A4&) {}
+
+} // detail
+} // lambda
+} // boost
+
+// prevent the warnings from unused arguments
+#define CALL_USE_ARGS \
+::ndnboost::lambda::detail::do_nothing(a, b, c, env)
+
+
+
+#endif
diff --git a/ndnboost/lambda/detail/lambda_traits.hpp b/ndnboost/lambda/detail/lambda_traits.hpp
new file mode 100644
index 0000000..aa241b6
--- /dev/null
+++ b/ndnboost/lambda/detail/lambda_traits.hpp
@@ -0,0 +1,578 @@
+// - lambda_traits.hpp --- Boost Lambda Library ----------------------------
+//
+// Copyright (C) 1999, 2000 Jaakko Jarvi (jaakko.jarvi@cs.utu.fi)
+//
+// Distributed under the Boost Software License, Version 1.0. (See
+// accompanying file LICENSE_1_0.txt or copy at
+// http://www.boost.org/LICENSE_1_0.txt)
+//
+// For more information, see www.boost.org
+// -------------------------------------------------------------------------
+
+#ifndef BOOST_LAMBDA_LAMBDA_TRAITS_HPP
+#define BOOST_LAMBDA_LAMBDA_TRAITS_HPP
+
+#include "ndnboost/type_traits/transform_traits.hpp"
+#include "ndnboost/type_traits/cv_traits.hpp"
+#include "ndnboost/type_traits/function_traits.hpp"
+#include "ndnboost/type_traits/object_traits.hpp"
+#include "ndnboost/tuple/tuple.hpp"
+
+namespace ndnboost {
+namespace lambda {
+
+// -- if construct ------------------------------------------------
+// Proposed by Krzysztof Czarnecki and Ulrich Eisenecker
+
+namespace detail {
+
+template <bool If, class Then, class Else> struct IF { typedef Then RET; };
+
+template <class Then, class Else> struct IF<false, Then, Else> {
+  typedef Else RET;
+};
+
+
+// An if construct that doesn't instantiate the non-matching template:
+
+// Called as: 
+//  IF_type<condition, A, B>::type 
+// The matching template must define the typeded 'type'
+// I.e. A::type if condition is true, B::type if condition is false
+// Idea from Vesa Karvonen (from C&E as well I guess)
+template<class T>
+struct IF_type_
+{
+  typedef typename T::type type;
+};
+
+
+template<bool C, class T, class E>
+struct IF_type
+{
+  typedef typename
+    IF_type_<typename IF<C, T, E>::RET >::type type;
+};
+
+// helper that can be used to give typedef T to some type
+template <class T> struct identity_mapping { typedef T type; };
+
+// An if construct for finding an integral constant 'value'
+// Does not instantiate the non-matching branch
+// Called as IF_value<condition, A, B>::value
+// If condition is true A::value must be defined, otherwise B::value
+
+template<class T>
+struct IF_value_
+{
+  BOOST_STATIC_CONSTANT(int, value = T::value);
+};
+
+
+template<bool C, class T, class E>
+struct IF_value
+{
+  BOOST_STATIC_CONSTANT(int, value = (IF_value_<typename IF<C, T, E>::RET>::value));
+};
+
+
+// --------------------------------------------------------------
+
+// removes reference from other than function types:
+template<class T> class remove_reference_if_valid
+{
+
+  typedef typename ndnboost::remove_reference<T>::type plainT;
+public:
+  typedef typename IF<
+    ndnboost::is_function<plainT>::value,
+    T,
+    plainT
+  >::RET type;
+
+};
+
+
+template<class T> struct remove_reference_and_cv {
+   typedef typename ndnboost::remove_cv<
+     typename ndnboost::remove_reference<T>::type
+   >::type type;
+};
+
+
+   
+// returns a reference to the element of tuple T
+template<int N, class T> struct tuple_element_as_reference {   
+  typedef typename
+     ndnboost::tuples::access_traits<
+       typename ndnboost::tuples::element<N, T>::type
+     >::non_const_type type;
+};
+
+// returns the cv and reverence stripped type of a tuple element
+template<int N, class T> struct tuple_element_stripped {   
+  typedef typename
+     remove_reference_and_cv<
+       typename ndnboost::tuples::element<N, T>::type
+     >::type type;
+};
+
+// is_lambda_functor -------------------------------------------------   
+
+template <class T> struct is_lambda_functor_ {
+  BOOST_STATIC_CONSTANT(bool, value = false);
+};
+   
+template <class Arg> struct is_lambda_functor_<lambda_functor<Arg> > {
+  BOOST_STATIC_CONSTANT(bool, value = true);
+};
+   
+} // end detail
+
+   
+template <class T> struct is_lambda_functor {
+  BOOST_STATIC_CONSTANT(bool, 
+     value = 
+       detail::is_lambda_functor_<
+         typename detail::remove_reference_and_cv<T>::type
+       >::value);
+};
+   
+
+namespace detail {
+
+// -- parameter_traits_ ---------------------------------------------
+
+// An internal parameter type traits class that respects
+// the reference_wrapper class.
+
+// The conversions performed are:
+// references -> compile_time_error
+// T1 -> T2, 
+// reference_wrapper<T> -> T&
+// const array -> ref to const array
+// array -> ref to array
+// function -> ref to function
+
+// ------------------------------------------------------------------------
+
+template<class T1, class T2> 
+struct parameter_traits_ {
+  typedef T2 type;
+};
+
+// Do not instantiate with reference types
+template<class T, class Any> struct parameter_traits_<T&, Any> {
+  typedef typename 
+    generate_error<T&>::
+      parameter_traits_class_instantiated_with_reference_type type;
+};
+
+// Arrays can't be stored as plain types; convert them to references
+template<class T, int n, class Any> struct parameter_traits_<T[n], Any> {
+  typedef T (&type)[n];
+};
+   
+template<class T, int n, class Any> 
+struct parameter_traits_<const T[n], Any> {
+  typedef const T (&type)[n];
+};
+
+template<class T, int n, class Any> 
+struct parameter_traits_<volatile T[n], Any> {
+  typedef volatile  T (&type)[n];
+};
+template<class T, int n, class Any> 
+struct parameter_traits_<const volatile T[n], Any> {
+  typedef const volatile T (&type)[n];
+};
+
+
+template<class T, class Any> 
+struct parameter_traits_<ndnboost::reference_wrapper<T>, Any >{
+  typedef T& type;
+};
+
+template<class T, class Any> 
+struct parameter_traits_<const ndnboost::reference_wrapper<T>, Any >{
+  typedef T& type;
+};
+
+template<class T, class Any> 
+struct parameter_traits_<volatile ndnboost::reference_wrapper<T>, Any >{
+  typedef T& type;
+};
+
+template<class T, class Any> 
+struct parameter_traits_<const volatile ndnboost::reference_wrapper<T>, Any >{
+  typedef T& type;
+};
+
+template<class Any>
+struct parameter_traits_<void, Any> {
+  typedef void type;
+};
+
+template<class Arg, class Any>
+struct parameter_traits_<lambda_functor<Arg>, Any > {
+  typedef lambda_functor<Arg> type;
+};
+
+template<class Arg, class Any>
+struct parameter_traits_<const lambda_functor<Arg>, Any > {
+  typedef lambda_functor<Arg> type;
+};
+
+// Are the volatile versions needed?
+template<class Arg, class Any>
+struct parameter_traits_<volatile lambda_functor<Arg>, Any > {
+  typedef lambda_functor<Arg> type;
+};
+
+template<class Arg, class Any>
+struct parameter_traits_<const volatile lambda_functor<Arg>, Any > {
+  typedef lambda_functor<Arg> type;
+};
+
+} // end namespace detail
+
+
+// ------------------------------------------------------------------------
+// traits classes for lambda expressions (bind functions, operators ...)   
+
+// must be instantiated with non-reference types
+
+// The default is const plain type -------------------------
+// const T -> const T, 
+// T -> const T, 
+// references -> compile_time_error
+// reference_wrapper<T> -> T&
+// array -> const ref array
+template<class T>
+struct const_copy_argument {
+  typedef typename 
+    detail::parameter_traits_<
+      T,
+      typename detail::IF<ndnboost::is_function<T>::value, T&, const T>::RET
+    >::type type;
+};
+
+// T may be a function type. Without the IF test, const would be added 
+// to a function type, which is illegal.
+
+// all arrays are converted to const.
+// This traits template is used for 'const T&' parameter passing 
+// and thus the knowledge of the potential 
+// non-constness of an actual argument is lost.   
+template<class T, int n>  struct const_copy_argument <T[n]> {
+  typedef const T (&type)[n];
+};
+template<class T, int n>  struct const_copy_argument <volatile T[n]> {
+     typedef const volatile T (&type)[n];
+};
+   
+template<class T>
+struct const_copy_argument<T&> {};
+// do not instantiate with references
+  //  typedef typename detail::generate_error<T&>::references_not_allowed type;
+
+
+template<>
+struct const_copy_argument<void> {
+  typedef void type;
+};
+
+
+// Does the same as const_copy_argument, but passes references through as such
+template<class T>
+struct bound_argument_conversion {
+  typedef typename const_copy_argument<T>::type type; 
+};
+
+template<class T>
+struct bound_argument_conversion<T&> {
+  typedef T& type; 
+};
+   
+// The default is non-const reference -------------------------
+// const T -> const T&, 
+// T -> T&, 
+// references -> compile_time_error
+// reference_wrapper<T> -> T&
+template<class T>
+struct reference_argument {
+  typedef typename detail::parameter_traits_<T, T&>::type type; 
+};
+
+template<class T>
+struct reference_argument<T&> {
+  typedef typename detail::generate_error<T&>::references_not_allowed type; 
+};
+
+template<class Arg>
+struct reference_argument<lambda_functor<Arg> > {
+  typedef lambda_functor<Arg> type;
+};
+
+template<class Arg>
+struct reference_argument<const lambda_functor<Arg> > {
+  typedef lambda_functor<Arg> type;
+};
+
+// Are the volatile versions needed?
+template<class Arg>
+struct reference_argument<volatile lambda_functor<Arg> > {
+  typedef lambda_functor<Arg> type;
+};
+
+template<class Arg>
+struct reference_argument<const volatile lambda_functor<Arg> > {
+  typedef lambda_functor<Arg> type;
+};
+
+template<>
+struct reference_argument<void> {
+  typedef void type;
+};
+
+namespace detail {
+   
+// Array to pointer conversion
+template <class T>
+struct array_to_pointer { 
+  typedef T type;
+};
+
+template <class T, int N>
+struct array_to_pointer <const T[N]> { 
+  typedef const T* type;
+};
+template <class T, int N>
+struct array_to_pointer <T[N]> { 
+  typedef T* type;
+};
+
+template <class T, int N>
+struct array_to_pointer <const T (&) [N]> { 
+  typedef const T* type;
+};
+template <class T, int N>
+struct array_to_pointer <T (&) [N]> { 
+  typedef T* type;
+};
+
+
+// ---------------------------------------------------------------------------
+// The call_traits for bind
+// Respects the reference_wrapper class.
+
+// These templates are used outside of bind functions as well.
+// the bind_tuple_mapper provides a shorter notation for default
+// bound argument storing semantics, if all arguments are treated
+// uniformly.
+
+// from template<class T> foo(const T& t) : bind_traits<const T>::type
+// from template<class T> foo(T& t) : bind_traits<T>::type
+
+// Conversions:
+// T -> const T,
+// cv T -> cv T, 
+// T& -> T& 
+// reference_wrapper<T> -> T&
+// const reference_wrapper<T> -> T&
+// array -> const ref array
+
+// make bound arguments const, this is a deliberate design choice, the
+// purpose is to prevent side effects to bound arguments that are stored
+// as copies
+template<class T>
+struct bind_traits {
+  typedef const T type; 
+};
+
+template<class T>
+struct bind_traits<T&> {
+  typedef T& type; 
+};
+
+// null_types are an exception, we always want to store them as non const
+// so that other templates can assume that null_type is always without const
+template<>
+struct bind_traits<null_type> {
+  typedef null_type type;
+};
+
+// the bind_tuple_mapper, bind_type_generators may 
+// introduce const to null_type
+template<>
+struct bind_traits<const null_type> {
+  typedef null_type type;
+};
+
+// Arrays can't be stored as plain types; convert them to references.
+// All arrays are converted to const. This is because bind takes its
+// parameters as const T& and thus the knowledge of the potential 
+// non-constness of actual argument is lost.
+template<class T, int n>  struct bind_traits <T[n]> {
+  typedef const T (&type)[n];
+};
+
+template<class T, int n> 
+struct bind_traits<const T[n]> {
+  typedef const T (&type)[n];
+};
+
+template<class T, int n>  struct bind_traits<volatile T[n]> {
+  typedef const volatile T (&type)[n];
+};
+
+template<class T, int n> 
+struct bind_traits<const volatile T[n]> {
+  typedef const volatile T (&type)[n];
+};
+
+template<class R>
+struct bind_traits<R()> {
+    typedef R(&type)();
+};
+
+template<class R, class Arg1>
+struct bind_traits<R(Arg1)> {
+    typedef R(&type)(Arg1);
+};
+
+template<class R, class Arg1, class Arg2>
+struct bind_traits<R(Arg1, Arg2)> {
+    typedef R(&type)(Arg1, Arg2);
+};
+
+template<class R, class Arg1, class Arg2, class Arg3>
+struct bind_traits<R(Arg1, Arg2, Arg3)> {
+    typedef R(&type)(Arg1, Arg2, Arg3);
+};
+
+template<class R, class Arg1, class Arg2, class Arg3, class Arg4>
+struct bind_traits<R(Arg1, Arg2, Arg3, Arg4)> {
+    typedef R(&type)(Arg1, Arg2, Arg3, Arg4);
+};
+
+template<class R, class Arg1, class Arg2, class Arg3, class Arg4, class Arg5>
+struct bind_traits<R(Arg1, Arg2, Arg3, Arg4, Arg5)> {
+    typedef R(&type)(Arg1, Arg2, Arg3, Arg4, Arg5);
+};
+
+template<class R, class Arg1, class Arg2, class Arg3, class Arg4, class Arg5, class Arg6>
+struct bind_traits<R(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6)> {
+    typedef R(&type)(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6);
+};
+
+template<class R, class Arg1, class Arg2, class Arg3, class Arg4, class Arg5, class Arg6, class Arg7>
+struct bind_traits<R(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7)> {
+    typedef R(&type)(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7);
+};
+
+template<class R, class Arg1, class Arg2, class Arg3, class Arg4, class Arg5, class Arg6, class Arg7, class Arg8>
+struct bind_traits<R(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7, Arg8)> {
+    typedef R(&type)(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7, Arg8);
+};
+
+template<class R, class Arg1, class Arg2, class Arg3, class Arg4, class Arg5, class Arg6, class Arg7, class Arg8, class Arg9>
+struct bind_traits<R(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7, Arg8, Arg9)> {
+    typedef R(&type)(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7, Arg8, Arg9);
+};
+
+template<class T> 
+struct bind_traits<reference_wrapper<T> >{
+  typedef T& type;
+};
+
+template<class T> 
+struct bind_traits<const reference_wrapper<T> >{
+  typedef T& type;
+};
+
+template<>
+struct bind_traits<void> {
+  typedef void type;
+};
+
+
+
+template <
+  class T0 = null_type, class T1 = null_type, class T2 = null_type, 
+  class T3 = null_type, class T4 = null_type, class T5 = null_type, 
+  class T6 = null_type, class T7 = null_type, class T8 = null_type, 
+  class T9 = null_type
+>
+struct bind_tuple_mapper {
+  typedef
+    tuple<typename bind_traits<T0>::type, 
+          typename bind_traits<T1>::type, 
+          typename bind_traits<T2>::type, 
+          typename bind_traits<T3>::type, 
+          typename bind_traits<T4>::type, 
+          typename bind_traits<T5>::type, 
+          typename bind_traits<T6>::type, 
+          typename bind_traits<T7>::type,
+          typename bind_traits<T8>::type,
+          typename bind_traits<T9>::type> type;
+};
+
+// bind_traits, except map const T& -> const T
+  // this is needed e.g. in currying. Const reference arguments can
+  // refer to temporaries, so it is not safe to store them as references.
+  template <class T> struct remove_const_reference {
+    typedef typename bind_traits<T>::type type;
+  };
+
+  template <class T> struct remove_const_reference<const T&> {
+    typedef const T type;
+  };
+
+
+// maps the bind argument types to the resulting lambda functor type
+template <
+  class T0 = null_type, class T1 = null_type, class T2 = null_type, 
+  class T3 = null_type, class T4 = null_type, class T5 = null_type, 
+  class T6 = null_type, class T7 = null_type, class T8 = null_type, 
+  class T9 = null_type
+>
+class bind_type_generator {
+
+  typedef typename
+  detail::bind_tuple_mapper<
+    T0, T1, T2, T3, T4, T5, T6, T7, T8, T9
+  >::type args_t;
+
+  BOOST_STATIC_CONSTANT(int, nof_elems = ndnboost::tuples::length<args_t>::value);
+
+  typedef 
+    action<
+      nof_elems, 
+      function_action<nof_elems>
+    > action_type;
+
+public:
+  typedef
+    lambda_functor<
+      lambda_functor_base<
+        action_type, 
+        args_t
+      >
+    > type; 
+    
+};
+
+
+   
+} // detail
+   
+template <class T> inline const T&  make_const(const T& t) { return t; }
+
+
+} // end of namespace lambda
+} // end of namespace ndnboost
+
+
+   
+#endif // BOOST_LAMBDA_TRAITS_HPP
diff --git a/ndnboost/lambda/detail/member_ptr.hpp b/ndnboost/lambda/detail/member_ptr.hpp
new file mode 100644
index 0000000..37c10ab
--- /dev/null
+++ b/ndnboost/lambda/detail/member_ptr.hpp
@@ -0,0 +1,737 @@
+// Boost Lambda Library -- member_ptr.hpp ---------------------
+
+// Copyright (C) 1999, 2000 Jaakko Jarvi (jaakko.jarvi@cs.utu.fi)
+// Copyright (C) 2000 Gary Powell (gary.powell@sierra.com)
+//
+// Distributed under the Boost Software License, Version 1.0. (See
+// accompanying file LICENSE_1_0.txt or copy at
+// http://www.boost.org/LICENSE_1_0.txt)
+//
+// For more information, see www.boost.org
+
+// --------------------------------------------------------------------------
+
+#if !defined(BOOST_LAMBDA_MEMBER_PTR_HPP)
+#define BOOST_LAMBDA_MEMBER_PTR_HPP
+
+namespace ndnboost { 
+namespace lambda {
+
+
+class member_pointer_action {};
+
+
+namespace detail {
+
+// the boost type_traits member_pointer traits are not enough, 
+// need to know more details.
+template<class T>
+struct member_pointer {
+  typedef typename ndnboost::add_reference<T>::type type;
+  typedef detail::unspecified class_type;
+  typedef detail::unspecified qualified_class_type;
+  BOOST_STATIC_CONSTANT(bool, is_data_member = false);
+  BOOST_STATIC_CONSTANT(bool, is_function_member = false);
+};
+
+template<class T, class U>
+struct member_pointer<T U::*> {
+  typedef typename ndnboost::add_reference<T>::type type;
+  typedef U class_type;
+  typedef U qualified_class_type;
+  BOOST_STATIC_CONSTANT(bool, is_data_member = true);
+  BOOST_STATIC_CONSTANT(bool, is_function_member = false);
+};
+
+template<class T, class U>
+struct member_pointer<const T U::*> {
+  typedef typename ndnboost::add_reference<const T>::type type;
+  typedef U class_type;
+  typedef const U qualified_class_type;
+  BOOST_STATIC_CONSTANT(bool, is_data_member = true);
+  BOOST_STATIC_CONSTANT(bool, is_function_member = false);
+};
+
+template<class T, class U>
+struct member_pointer<volatile T U::*> {
+  typedef typename ndnboost::add_reference<volatile T>::type type;
+  typedef U class_type;
+  typedef volatile U qualified_class_type;
+  BOOST_STATIC_CONSTANT(bool, is_data_member = true);
+  BOOST_STATIC_CONSTANT(bool, is_function_member = false);
+};
+
+template<class T, class U>
+struct member_pointer<const volatile T U::*> {
+  typedef typename ndnboost::add_reference<const volatile T>::type type;
+  typedef U class_type;
+  typedef const volatile U qualified_class_type;
+  BOOST_STATIC_CONSTANT(bool, is_data_member = true);
+  BOOST_STATIC_CONSTANT(bool, is_function_member = false);
+};
+
+// -- nonconst member functions --
+template<class T, class U>
+struct member_pointer<T (U::*)()> {
+  typedef T type;
+  typedef U class_type;
+  typedef U qualified_class_type;
+  BOOST_STATIC_CONSTANT(bool, is_data_member = false);
+  BOOST_STATIC_CONSTANT(bool, is_function_member = true);
+};
+template<class T, class U, class A1>
+struct member_pointer<T (U::*)(A1)> {
+  typedef T type;
+  typedef U class_type;
+  typedef U qualified_class_type;
+  BOOST_STATIC_CONSTANT(bool, is_data_member = false);
+  BOOST_STATIC_CONSTANT(bool, is_function_member = true);
+};
+template<class T, class U, class A1, class A2>
+struct member_pointer<T (U::*)(A1, A2)> {
+  typedef T type;
+  typedef U class_type;
+  typedef U qualified_class_type;
+  BOOST_STATIC_CONSTANT(bool, is_data_member = false);
+  BOOST_STATIC_CONSTANT(bool, is_function_member = true);
+};
+template<class T, class U, class A1, class A2, class A3>
+struct member_pointer<T (U::*)(A1, A2, A3)> {
+  typedef T type;
+  typedef U class_type;
+  typedef U qualified_class_type;
+  BOOST_STATIC_CONSTANT(bool, is_data_member = false);
+  BOOST_STATIC_CONSTANT(bool, is_function_member = true);
+};
+template<class T, class U, class A1, class A2, class A3, class A4>
+struct member_pointer<T (U::*)(A1, A2, A3, A4)> {
+  typedef T type;
+  typedef U class_type;
+  typedef U qualified_class_type;
+  BOOST_STATIC_CONSTANT(bool, is_data_member = false);
+  BOOST_STATIC_CONSTANT(bool, is_function_member = true);
+};
+template<class T, class U, class A1, class A2, class A3, class A4, class A5>
+struct member_pointer<T (U::*)(A1, A2, A3, A4, A5)> {
+  typedef T type;
+  typedef U class_type;
+  typedef U qualified_class_type;
+  BOOST_STATIC_CONSTANT(bool, is_data_member = false);
+  BOOST_STATIC_CONSTANT(bool, is_function_member = true);
+};
+template<class T, class U, class A1, class A2, class A3, class A4, class A5,
+         class A6>
+struct member_pointer<T (U::*)(A1, A2, A3, A4, A5, A6)> {
+  typedef T type;
+  typedef U class_type;
+  typedef U qualified_class_type;
+  BOOST_STATIC_CONSTANT(bool, is_data_member = false);
+  BOOST_STATIC_CONSTANT(bool, is_function_member = true);
+};
+template<class T, class U, class A1, class A2, class A3, class A4, class A5,
+         class A6, class A7>
+struct member_pointer<T (U::*)(A1, A2, A3, A4, A5, A6, A7)> {
+  typedef T type;
+  typedef U class_type;
+  typedef U qualified_class_type;
+  BOOST_STATIC_CONSTANT(bool, is_data_member = false);
+  BOOST_STATIC_CONSTANT(bool, is_function_member = true);
+};
+template<class T, class U, class A1, class A2, class A3, class A4, class A5,
+         class A6, class A7, class A8>
+struct member_pointer<T (U::*)(A1, A2, A3, A4, A5, A6, A7, A8)> {
+  typedef T type;
+  typedef U class_type;
+  typedef U qualified_class_type;
+  BOOST_STATIC_CONSTANT(bool, is_data_member = false);
+  BOOST_STATIC_CONSTANT(bool, is_function_member = true);
+};
+template<class T, class U, class A1, class A2, class A3, class A4, class A5,
+         class A6, class A7, class A8, class A9>
+struct member_pointer<T (U::*)(A1, A2, A3, A4, A5, A6, A7, A8, A9)> {
+  typedef T type;
+  typedef U class_type;
+  typedef U qualified_class_type;
+  BOOST_STATIC_CONSTANT(bool, is_data_member = false);
+  BOOST_STATIC_CONSTANT(bool, is_function_member = true);
+};
+// -- const member functions --
+template<class T, class U>
+struct member_pointer<T (U::*)() const> {
+  typedef T type;
+  typedef U class_type;
+  typedef const U qualified_class_type;
+  BOOST_STATIC_CONSTANT(bool, is_data_member = false);
+  BOOST_STATIC_CONSTANT(bool, is_function_member = true);
+};
+template<class T, class U, class A1>
+struct member_pointer<T (U::*)(A1) const> {
+  typedef T type;
+  typedef U class_type;
+  typedef const U qualified_class_type;
+  BOOST_STATIC_CONSTANT(bool, is_data_member = false);
+  BOOST_STATIC_CONSTANT(bool, is_function_member = true);
+};
+template<class T, class U, class A1, class A2>
+struct member_pointer<T (U::*)(A1, A2) const> {
+  typedef T type;
+  typedef U class_type;
+  typedef const U qualified_class_type;
+  BOOST_STATIC_CONSTANT(bool, is_data_member = false);
+  BOOST_STATIC_CONSTANT(bool, is_function_member = true);
+};
+template<class T, class U, class A1, class A2, class A3>
+struct member_pointer<T (U::*)(A1, A2, A3) const> {
+  typedef T type;
+  typedef U class_type;
+  typedef const U qualified_class_type;
+  BOOST_STATIC_CONSTANT(bool, is_data_member = false);
+  BOOST_STATIC_CONSTANT(bool, is_function_member = true);
+};
+template<class T, class U, class A1, class A2, class A3, class A4>
+struct member_pointer<T (U::*)(A1, A2, A3, A4) const> {
+  typedef T type;
+  typedef U class_type;
+  typedef const U qualified_class_type;
+  BOOST_STATIC_CONSTANT(bool, is_data_member = false);
+  BOOST_STATIC_CONSTANT(bool, is_function_member = true);
+};
+template<class T, class U, class A1, class A2, class A3, class A4, class A5>
+struct member_pointer<T (U::*)(A1, A2, A3, A4, A5) const> {
+  typedef T type;
+  typedef U class_type;
+  typedef const U qualified_class_type;
+  BOOST_STATIC_CONSTANT(bool, is_data_member = false);
+  BOOST_STATIC_CONSTANT(bool, is_function_member = true);
+};
+template<class T, class U, class A1, class A2, class A3, class A4, class A5,
+         class A6>
+struct member_pointer<T (U::*)(A1, A2, A3, A4, A5, A6) const> {
+  typedef T type;
+  typedef U class_type;
+  typedef const U qualified_class_type;
+  BOOST_STATIC_CONSTANT(bool, is_data_member = false);
+  BOOST_STATIC_CONSTANT(bool, is_function_member = true);
+};
+template<class T, class U, class A1, class A2, class A3, class A4, class A5,
+         class A6, class A7>
+struct member_pointer<T (U::*)(A1, A2, A3, A4, A5, A6, A7) const> {
+  typedef T type;
+  typedef U class_type;
+  typedef const U qualified_class_type;
+  BOOST_STATIC_CONSTANT(bool, is_data_member = false);
+  BOOST_STATIC_CONSTANT(bool, is_function_member = true);
+};
+template<class T, class U, class A1, class A2, class A3, class A4, class A5,
+         class A6, class A7, class A8>
+struct member_pointer<T (U::*)(A1, A2, A3, A4, A5, A6, A7, A8) const> {
+  typedef T type;
+  typedef U class_type;
+  typedef const U qualified_class_type;
+  BOOST_STATIC_CONSTANT(bool, is_data_member = false);
+  BOOST_STATIC_CONSTANT(bool, is_function_member = true);
+};
+template<class T, class U, class A1, class A2, class A3, class A4, class A5,
+         class A6, class A7, class A8, class A9>
+struct member_pointer<T (U::*)(A1, A2, A3, A4, A5, A6, A7, A8, A9) const> {
+  typedef T type;
+  typedef U class_type;
+  typedef const U qualified_class_type;
+  BOOST_STATIC_CONSTANT(bool, is_data_member = false);
+  BOOST_STATIC_CONSTANT(bool, is_function_member = true);
+};
+  // -- volatile --
+template<class T, class U>
+struct member_pointer<T (U::*)() volatile> {
+  typedef T type;
+  typedef U class_type;
+  typedef volatile U qualified_class_type;
+  BOOST_STATIC_CONSTANT(bool, is_data_member = false);
+  BOOST_STATIC_CONSTANT(bool, is_function_member = true);
+};
+template<class T, class U, class A1>
+struct member_pointer<T (U::*)(A1) volatile> {
+  typedef T type;
+  typedef U class_type;
+  typedef volatile U qualified_class_type;
+  BOOST_STATIC_CONSTANT(bool, is_data_member = false);
+  BOOST_STATIC_CONSTANT(bool, is_function_member = true);
+};
+template<class T, class U, class A1, class A2>
+struct member_pointer<T (U::*)(A1, A2) volatile> {
+  typedef T type;
+  typedef U class_type;
+  typedef volatile U qualified_class_type;
+  BOOST_STATIC_CONSTANT(bool, is_data_member = false);
+  BOOST_STATIC_CONSTANT(bool, is_function_member = true);
+};
+template<class T, class U, class A1, class A2, class A3>
+struct member_pointer<T (U::*)(A1, A2, A3) volatile> {
+  typedef T type;
+  typedef U class_type;
+  typedef volatile U qualified_class_type;
+  BOOST_STATIC_CONSTANT(bool, is_data_member = false);
+  BOOST_STATIC_CONSTANT(bool, is_function_member = true);
+};
+template<class T, class U, class A1, class A2, class A3, class A4>
+struct member_pointer<T (U::*)(A1, A2, A3, A4) volatile> {
+  typedef T type;
+  typedef U class_type;
+  typedef volatile U qualified_class_type;
+  BOOST_STATIC_CONSTANT(bool, is_data_member = false);
+  BOOST_STATIC_CONSTANT(bool, is_function_member = true);
+};
+template<class T, class U, class A1, class A2, class A3, class A4, class A5>
+struct member_pointer<T (U::*)(A1, A2, A3, A4, A5) volatile> {
+  typedef T type;
+  typedef U class_type;
+  typedef volatile U qualified_class_type;
+  BOOST_STATIC_CONSTANT(bool, is_data_member = false);
+  BOOST_STATIC_CONSTANT(bool, is_function_member = true);
+};
+template<class T, class U, class A1, class A2, class A3, class A4, class A5,
+         class A6>
+struct member_pointer<T (U::*)(A1, A2, A3, A4, A5, A6) volatile> {
+  typedef T type;
+  typedef U class_type;
+  typedef volatile U qualified_class_type;
+  BOOST_STATIC_CONSTANT(bool, is_data_member = false);
+  BOOST_STATIC_CONSTANT(bool, is_function_member = true);
+};
+template<class T, class U, class A1, class A2, class A3, class A4, class A5,
+         class A6, class A7>
+struct member_pointer<T (U::*)(A1, A2, A3, A4, A5, A6, A7) volatile> {
+  typedef T type;
+  typedef U class_type;
+  typedef volatile U qualified_class_type;
+  BOOST_STATIC_CONSTANT(bool, is_data_member = false);
+  BOOST_STATIC_CONSTANT(bool, is_function_member = true);
+};
+template<class T, class U, class A1, class A2, class A3, class A4, class A5,
+         class A6, class A7, class A8>
+struct member_pointer<T (U::*)(A1, A2, A3, A4, A5, A6, A7, A8) volatile> {
+  typedef T type;
+  typedef U class_type;
+  typedef volatile U qualified_class_type;
+  BOOST_STATIC_CONSTANT(bool, is_data_member = false);
+  BOOST_STATIC_CONSTANT(bool, is_function_member = true);
+};
+template<class T, class U, class A1, class A2, class A3, class A4, class A5,
+         class A6, class A7, class A8, class A9>
+struct member_pointer<T (U::*)(A1, A2, A3, A4, A5, A6, A7, A8, A9) volatile> {
+  typedef T type;
+  typedef U class_type;
+  typedef volatile U qualified_class_type;
+  BOOST_STATIC_CONSTANT(bool, is_data_member = false);
+  BOOST_STATIC_CONSTANT(bool, is_function_member = true);
+};
+  // -- const volatile
+template<class T, class U>
+struct member_pointer<T (U::*)() const volatile> {
+  typedef T type;
+  typedef U class_type;
+  typedef const volatile U qualified_class_type;
+  BOOST_STATIC_CONSTANT(bool, is_data_member = false);
+  BOOST_STATIC_CONSTANT(bool, is_function_member = true);
+};
+template<class T, class U, class A1>
+struct member_pointer<T (U::*)(A1) const volatile> {
+  typedef T type;
+  typedef U class_type;
+  typedef const volatile U qualified_class_type;
+  BOOST_STATIC_CONSTANT(bool, is_data_member = false);
+  BOOST_STATIC_CONSTANT(bool, is_function_member = true);
+};
+template<class T, class U, class A1, class A2>
+struct member_pointer<T (U::*)(A1, A2) const volatile> {
+  typedef T type;
+  typedef U class_type;
+  typedef const volatile U qualified_class_type;
+  BOOST_STATIC_CONSTANT(bool, is_data_member = false);
+  BOOST_STATIC_CONSTANT(bool, is_function_member = true);
+};
+template<class T, class U, class A1, class A2, class A3>
+struct member_pointer<T (U::*)(A1, A2, A3) const volatile> {
+  typedef T type;
+  typedef U class_type;
+  typedef const volatile U qualified_class_type;
+  BOOST_STATIC_CONSTANT(bool, is_data_member = false);
+  BOOST_STATIC_CONSTANT(bool, is_function_member = true);
+};
+template<class T, class U, class A1, class A2, class A3, class A4>
+struct member_pointer<T (U::*)(A1, A2, A3, A4) const volatile> {
+  typedef T type;
+  typedef U class_type;
+  typedef const volatile U qualified_class_type;
+};
+template<class T, class U, class A1, class A2, class A3, class A4, class A5>
+struct member_pointer<T (U::*)(A1, A2, A3, A4, A5) const volatile> {
+  typedef T type;
+  typedef U class_type;
+  typedef const volatile U qualified_class_type;
+  BOOST_STATIC_CONSTANT(bool, is_data_member = false);
+  BOOST_STATIC_CONSTANT(bool, is_function_member = true);
+};
+template<class T, class U, class A1, class A2, class A3, class A4, class A5,
+         class A6>
+struct member_pointer<T (U::*)(A1, A2, A3, A4, A5, A6) const volatile> {
+  typedef T type;
+  typedef U class_type;
+  typedef const volatile U qualified_class_type;
+  BOOST_STATIC_CONSTANT(bool, is_data_member = false);
+  BOOST_STATIC_CONSTANT(bool, is_function_member = true);
+};
+template<class T, class U, class A1, class A2, class A3, class A4, class A5,
+         class A6, class A7>
+struct member_pointer<T (U::*)(A1, A2, A3, A4, A5, A6, A7) const volatile> {
+  typedef T type;
+  typedef U class_type;
+  typedef const volatile U qualified_class_type;
+  BOOST_STATIC_CONSTANT(bool, is_data_member = false);
+  BOOST_STATIC_CONSTANT(bool, is_function_member = true);
+};
+template<class T, class U, class A1, class A2, class A3, class A4, class A5,
+         class A6, class A7, class A8>
+struct member_pointer<T (U::*)(A1, A2, A3, A4, A5, A6, A7, A8) const volatile> {
+  typedef T type;
+  typedef U class_type;
+  typedef const volatile U qualified_class_type;
+  BOOST_STATIC_CONSTANT(bool, is_data_member = false);
+  BOOST_STATIC_CONSTANT(bool, is_function_member = true);
+};
+template<class T, class U, class A1, class A2, class A3, class A4, class A5,
+         class A6, class A7, class A8, class A9>
+struct member_pointer<T (U::*)(A1, A2, A3, A4, A5, A6, A7, A8, A9) const volatile> {
+  typedef T type;
+  typedef U class_type;
+  typedef const volatile U qualified_class_type;
+  BOOST_STATIC_CONSTANT(bool, is_data_member = false);
+  BOOST_STATIC_CONSTANT(bool, is_function_member = true);
+};
+
+} // detail
+
+namespace detail {
+
+  // this class holds a pointer to a member function and the object.
+  // when called, it just calls the member function with the parameters 
+  // provided
+
+  // It would have been possible to use existing lambda_functors to represent
+  // a bound member function like this, but to have a separate template is 
+  // safer, since now this functor doesn't mix and match with lambda_functors
+  // only thing you can do with this is to call it
+
+  // note that previously instantiated classes 
+  // (other_action<member_pointer_action> and member_pointer_action_helper
+  // guarantee, that A and B are 
+  // such types, that for objects a and b of corresponding types, a->*b leads 
+  // to the builtin ->* to be called. So types that would end in a  call to 
+  // a user defined ->* do not create a member_pointer_caller object.
+
+template<class RET, class A, class B>
+class member_pointer_caller {
+  A a; B b;
+
+public:
+  member_pointer_caller(const A& aa, const B& bb) : a(aa), b(bb) {}
+
+  RET operator()() const { return (a->*b)(); } 
+
+  template<class A1>
+  RET operator()(const A1& a1) const { return (a->*b)(a1); } 
+
+  template<class A1, class A2>
+  RET operator()(const A1& a1, const A2& a2) const { return (a->*b)(a1, a2); } 
+
+  template<class A1, class A2, class A3>
+  RET operator()(const A1& a1, const A2& a2, const A3& a3) const { 
+    return (a->*b)(a1, a2, a3); 
+  } 
+
+  template<class A1, class A2, class A3, class A4>
+  RET operator()(const A1& a1, const A2& a2, const A3& a3, 
+                 const A4& a4) const { 
+    return (a->*b)(a1, a2, a3, a4); 
+  } 
+
+  template<class A1, class A2, class A3, class A4, class A5>
+  RET operator()(const A1& a1, const A2& a2, const A3& a3, const A4& a4, 
+                 const A5& a5) const { 
+    return (a->*b)(a1, a2, a3, a4, a5); 
+  } 
+
+  template<class A1, class A2, class A3, class A4, class A5, class A6>
+  RET operator()(const A1& a1, const A2& a2, const A3& a3, const A4& a4, 
+                 const A5& a5, const A6& a6) const { 
+    return (a->*b)(a1, a2, a3, a4, a5, a6); 
+  } 
+
+  template<class A1, class A2, class A3, class A4, class A5, class A6, 
+           class A7>
+  RET operator()(const A1& a1, const A2& a2, const A3& a3, const A4& a4, 
+                 const A5& a5, const A6& a6, const A7& a7) const { 
+    return (a->*b)(a1, a2, a3, a4, a5, a6, a7); 
+  } 
+
+  template<class A1, class A2, class A3, class A4, class A5, class A6, 
+           class A7, class A8>
+  RET operator()(const A1& a1, const A2& a2, const A3& a3, const A4& a4, 
+                 const A5& a5, const A6& a6, const A7& a7,
+                 const A8& a8) const { 
+    return (a->*b)(a1, a2, a3, a4, a5, a6, a7, a8); 
+  } 
+
+  template<class A1, class A2, class A3, class A4, class A5, class A6, 
+           class A7, class A8, class A9>
+  RET operator()(const A1& a1, const A2& a2, const A3& a3, const A4& a4, 
+                 const A5& a5, const A6& a6, const A7& a7,
+                 const A8& a8, const A9& a9) const { 
+    return (a->*b)(a1, a2, a3, a4, a5, a6, a7, a8, a9); 
+  } 
+
+};
+
+// helper templates for return type deduction and action classes
+// different cases for data member, function member, neither
+
+// true-true case
+template <bool Is_data_member, bool Is_function_member>
+struct member_pointer_action_helper;
+  // cannot be both, no body provided
+
+  // data member case
+  // this means, that B is a data member and A is a pointer type,
+  // so either built-in ->* should be called, or there is an error
+template <>
+struct member_pointer_action_helper<true, false> {
+public:
+
+  template<class RET, class A, class B>
+  static RET apply(A& a, B& b) { 
+    return a->*b; 
+  }
+
+  template<class A, class B>
+  struct return_type {
+  private:
+    typedef typename detail::remove_reference_and_cv<B>::type plainB;
+
+    typedef typename detail::member_pointer<plainB>::type type0;
+    // we remove the reference now, as we may have to add cv:s 
+    typedef typename ndnboost::remove_reference<type0>::type type1;
+
+    // A is a reference to pointer
+    // remove the top level cv qualifiers and reference
+    typedef typename 
+      detail::remove_reference_and_cv<A>::type non_ref_A;
+
+    // A is a pointer type, so take the type pointed to
+    typedef typename ::ndnboost::remove_pointer<non_ref_A>::type non_pointer_A; 
+
+  public:
+    // For non-reference types, we must add const and/or volatile if
+    // the pointer type has these qualifiers
+    // If the member is a reference, these do not have any effect
+    //   (cv T == T if T is a reference type)
+    typedef typename detail::IF<
+      ::ndnboost::is_const<non_pointer_A>::value, 
+      typename ::ndnboost::add_const<type1>::type,
+      type1
+    >::RET type2;
+    typedef typename detail::IF<
+      ::ndnboost::is_volatile<non_pointer_A>::value, 
+      typename ::ndnboost::add_volatile<type2>::type,
+      type2
+    >::RET type3;
+    // add reference back
+    typedef typename ::ndnboost::add_reference<type3>::type type;
+  };
+};
+
+  // neither case
+template <>
+struct member_pointer_action_helper<false, false> {
+public:
+  template<class RET, class A, class B>
+  static RET apply(A& a, B& b) { 
+// not a built in member pointer operator, just call ->*
+    return a->*b; 
+  }
+  // an overloaded member pointer operators, user should have specified
+  // the return type
+  // At this point we know that there is no matching specialization for
+  // return_type_2, so try return_type_2_plain
+  template<class A, class B>
+  struct return_type {
+
+    typedef typename plain_return_type_2<
+      other_action<member_pointer_action>, A, B
+    >::type type;
+  };
+  
+};
+
+
+// member pointer function case
+// This is a built in ->* call for a member function, 
+// the only thing that you can do with that, is to give it some arguments
+// note, it is guaranteed that A is a pointer type, and thus it cannot
+// be a call to overloaded ->*
+template <>
+struct member_pointer_action_helper<false, true> {
+  public:
+
+  template<class RET, class A, class B>
+  static RET apply(A& a, B& b) { 
+    typedef typename ::ndnboost::remove_cv<B>::type plainB;
+    typedef typename detail::member_pointer<plainB>::type ret_t; 
+    typedef typename ::ndnboost::remove_cv<A>::type plainA;
+
+    // we always strip cv:s to 
+    // make the two routes (calling and type deduction)
+    // to give the same results (and the const does not make any functional
+    // difference)
+    return detail::member_pointer_caller<ret_t, plainA, plainB>(a, b); 
+  }
+
+  template<class A, class B>
+  struct return_type {
+    typedef typename detail::remove_reference_and_cv<B>::type plainB;
+    typedef typename detail::member_pointer<plainB>::type ret_t; 
+    typedef typename detail::remove_reference_and_cv<A>::type plainA; 
+
+    typedef detail::member_pointer_caller<ret_t, plainA, plainB> type; 
+  };
+};
+
+} // detail
+
+template<> class other_action<member_pointer_action>  {
+public:
+  template<class RET, class A, class B>
+  static RET apply(A& a, B& b) {
+    typedef typename 
+      ::ndnboost::remove_cv<B>::type plainB;
+
+    return detail::member_pointer_action_helper<
+        ndnboost::is_pointer<A>::value && 
+          detail::member_pointer<plainB>::is_data_member,
+        ndnboost::is_pointer<A>::value && 
+          detail::member_pointer<plainB>::is_function_member
+      >::template apply<RET>(a, b); 
+    }
+};
+
+  // return type deduction --
+
+  // If the right argument is a pointer to data member, 
+  // and the left argument is of compatible pointer to class type
+  // return type is a reference to the data member type
+
+  // if right argument is a pointer to a member function, and the left 
+  // argument is of a compatible type, the return type is a 
+  // member_pointer_caller (see above)
+
+  // Otherwise, return type deduction fails. There is either an error, 
+  // or the user is trying to call an overloaded ->*
+  // In such a case either ret<> must be used, or a return_type_2 user 
+  // defined specialization must be provided
+
+
+template<class A, class B>
+struct return_type_2<other_action<member_pointer_action>, A, B> {
+private:
+  typedef typename 
+    detail::remove_reference_and_cv<B>::type plainB;
+public:
+  typedef typename 
+    detail::member_pointer_action_helper<
+      detail::member_pointer<plainB>::is_data_member,
+      detail::member_pointer<plainB>::is_function_member
+    >::template return_type<A, B>::type type; 
+};
+
+  // this is the way the generic lambda_functor_base functions instantiate
+  // return type deduction. We turn it into return_type_2, so that the 
+  // user can provide specializations on that level.
+template<class Args>
+struct return_type_N<other_action<member_pointer_action>, Args> {
+  typedef typename ndnboost::tuples::element<0, Args>::type A;
+  typedef typename ndnboost::tuples::element<1, Args>::type B;
+  typedef typename 
+    return_type_2<other_action<member_pointer_action>, 
+                  typename ndnboost::remove_reference<A>::type, 
+                  typename ndnboost::remove_reference<B>::type
+                 >::type type;
+};
+
+
+template<class Arg1, class Arg2>
+inline const
+lambda_functor<
+  lambda_functor_base<
+    action<2, other_action<member_pointer_action> >,
+    tuple<lambda_functor<Arg1>, typename const_copy_argument<Arg2>::type>
+  >
+>
+operator->*(const lambda_functor<Arg1>& a1, const Arg2& a2)
+{
+  return 
+      lambda_functor_base<
+        action<2, other_action<member_pointer_action> >,
+        tuple<lambda_functor<Arg1>, typename const_copy_argument<Arg2>::type>
+      >
+      (tuple<lambda_functor<Arg1>, 
+             typename const_copy_argument<Arg2>::type>(a1, a2));
+}
+
+template<class Arg1, class Arg2>
+inline const
+lambda_functor<
+  lambda_functor_base<
+    action<2, other_action<member_pointer_action> >,
+    tuple<lambda_functor<Arg1>, lambda_functor<Arg2> >
+  >
+>
+operator->*(const lambda_functor<Arg1>& a1, const lambda_functor<Arg2>& a2)
+{
+  return 
+      lambda_functor_base<
+        action<2, other_action<member_pointer_action> >,
+        tuple<lambda_functor<Arg1>, lambda_functor<Arg2> >
+      >
+    (tuple<lambda_functor<Arg1>, lambda_functor<Arg2> >(a1, a2));
+}
+
+template<class Arg1, class Arg2>
+inline const
+lambda_functor<
+  lambda_functor_base<
+    action<2, other_action<member_pointer_action> >,
+    tuple<typename const_copy_argument<Arg1>::type, lambda_functor<Arg2> >
+  >
+>
+operator->*(const Arg1& a1, const lambda_functor<Arg2>& a2)
+{
+  return 
+      lambda_functor_base<
+        action<2, other_action<member_pointer_action> >,
+        tuple<typename const_copy_argument<Arg1>::type, lambda_functor<Arg2> >
+      >
+      (tuple<typename const_copy_argument<Arg1>::type, 
+             lambda_functor<Arg2> >(a1, a2));
+}
+
+
+} // namespace lambda 
+} // namespace ndnboost
+
+
+#endif
+
+
+
+
+
+
diff --git a/ndnboost/lambda/detail/operator_actions.hpp b/ndnboost/lambda/detail/operator_actions.hpp
new file mode 100644
index 0000000..4947792
--- /dev/null
+++ b/ndnboost/lambda/detail/operator_actions.hpp
@@ -0,0 +1,139 @@
+// -- operator_actions.hpp - Boost Lambda Library ----------------------
+
+// Copyright (C) 1999, 2000 Jaakko Jarvi (jaakko.jarvi@cs.utu.fi)
+//
+// Distributed under the Boost Software License, Version 1.0. (See
+// accompanying file LICENSE_1_0.txt or copy at
+// http://www.boost.org/LICENSE_1_0.txt)
+
+// For more information, see http://lambda.cs.utu.fi 
+
+#ifndef BOOST_LAMBDA_OPERATOR_ACTIONS_HPP
+#define BOOST_LAMBDA_OPERATOR_ACTIONS_HPP
+
+namespace ndnboost { 
+namespace lambda {
+
+
+// -- artihmetic ----------------------
+
+class plus_action {};
+class minus_action {};
+class multiply_action {};
+class divide_action {};
+class remainder_action {};
+
+// -- bitwise  -------------------
+
+class leftshift_action {};
+class rightshift_action {};
+class xor_action {};
+
+
+// -- bitwise/logical -------------------
+
+class and_action {};
+class or_action {};
+class not_action {};
+
+// -- relational -------------------------
+
+class less_action {};
+class greater_action {};
+class lessorequal_action {};
+class greaterorequal_action {};
+class equal_action {};
+class notequal_action {};
+
+// -- increment/decrement ------------------------------
+
+class increment_action {};
+class decrement_action {};
+
+// -- void return ------------------------------
+
+// -- other  ------------------------------
+
+class addressof_action {};
+  // class comma_action {}; // defined in actions.hpp
+class contentsof_action {};
+// class member_pointer_action {}; (defined in member_ptr.hpp)
+
+
+// -- actioun group templates --------------------
+
+template <class Action> class arithmetic_action;
+template <class Action> class bitwise_action;
+template <class Action> class logical_action;
+template <class Action> class relational_action;
+template <class Action> class arithmetic_assignment_action;
+template <class Action> class bitwise_assignment_action;
+template <class Action> class unary_arithmetic_action;
+template <class Action> class pre_increment_decrement_action;
+template <class Action> class post_increment_decrement_action;
+
+// ---------------------------------------------------------
+
+  // actions, for which the existence of protect is checked in return type 
+  // deduction.
+
+template <class Act> struct is_protectable<arithmetic_action<Act> > {
+  BOOST_STATIC_CONSTANT(bool, value = true);
+};
+template <class Act> struct is_protectable<bitwise_action<Act> > {
+  BOOST_STATIC_CONSTANT(bool, value = true);
+};
+template <class Act> struct is_protectable<logical_action<Act> > {
+  BOOST_STATIC_CONSTANT(bool, value = true);
+};
+template <class Act> struct is_protectable<relational_action<Act> > {
+  BOOST_STATIC_CONSTANT(bool, value = true);
+};
+template <class Act> 
+struct is_protectable<arithmetic_assignment_action<Act> > {
+  BOOST_STATIC_CONSTANT(bool, value = true);
+};
+template <class Act> struct is_protectable<bitwise_assignment_action<Act> > {
+  BOOST_STATIC_CONSTANT(bool, value = true);
+};
+template <class Act> struct is_protectable<unary_arithmetic_action<Act> > {
+  BOOST_STATIC_CONSTANT(bool, value = true);
+};
+template <class Act> 
+struct is_protectable<pre_increment_decrement_action<Act> > {
+  BOOST_STATIC_CONSTANT(bool, value = true);
+};
+template <class Act> struct 
+is_protectable<post_increment_decrement_action<Act> > {
+  BOOST_STATIC_CONSTANT(bool, value = true);
+};
+
+template <> struct is_protectable<other_action<addressof_action> > {
+  BOOST_STATIC_CONSTANT(bool, value = true);
+};
+template <> struct is_protectable<other_action<contentsof_action> > {
+  BOOST_STATIC_CONSTANT(bool, value = true);
+};
+
+template<> struct is_protectable<other_action<subscript_action> > {
+  BOOST_STATIC_CONSTANT(bool, value = true);
+};
+template<> struct is_protectable<other_action<assignment_action> > {
+  BOOST_STATIC_CONSTANT(bool, value = true);
+};
+
+// NOTE: comma action is also protectable, but the specialization is
+  // in actions.hpp
+
+
+} // namespace lambda 
+} // namespace ndnboost
+
+#endif
+
+
+
+
+
+
+
diff --git a/ndnboost/lambda/detail/operator_lambda_func_base.hpp b/ndnboost/lambda/detail/operator_lambda_func_base.hpp
new file mode 100644
index 0000000..777726a
--- /dev/null
+++ b/ndnboost/lambda/detail/operator_lambda_func_base.hpp
@@ -0,0 +1,271 @@
+// Boost Lambda Library  - operator_lambda_func_base.hpp -----------------
+//
+// Copyright (C) 1999, 2000 Jaakko Jarvi (jaakko.jarvi@cs.utu.fi)
+//
+// Distributed under the Boost Software License, Version 1.0. (See
+// accompanying file LICENSE_1_0.txt or copy at
+// http://www.boost.org/LICENSE_1_0.txt)
+//
+// For more information, see www.boost.org
+
+// ------------------------------------------------------------
+
+#ifndef BOOST_LAMBDA_OPERATOR_LAMBDA_FUNC_BASE_HPP
+#define BOOST_LAMBDA_OPERATOR_LAMBDA_FUNC_BASE_HPP
+
+namespace ndnboost { 
+namespace lambda {
+
+
+// These operators cannot be implemented as apply functions of action 
+// templates
+
+
+// Specialization for comma.
+template<class Args>
+class lambda_functor_base<other_action<comma_action>, Args> {
+public:
+  Args args;
+public:
+  explicit lambda_functor_base(const Args& a) : args(a) {}
+
+  template<class RET, CALL_TEMPLATE_ARGS>
+  RET call(CALL_FORMAL_ARGS) const {
+    return detail::select(ndnboost::tuples::get<0>(args), CALL_ACTUAL_ARGS), 
+           detail::select(ndnboost::tuples::get<1>(args), CALL_ACTUAL_ARGS); 
+  }
+
+
+  template<class SigArgs> struct sig { 
+  private:
+    typedef typename
+      detail::deduce_argument_types<Args, SigArgs>::type rets_t;      
+  public:
+    typedef typename return_type_2_comma< // comma needs special handling
+      typename detail::element_or_null<0, rets_t>::type,
+      typename detail::element_or_null<1, rets_t>::type
+    >::type type;
+  };
+
+};  
+
+namespace detail {
+
+// helper traits to make the expression shorter, takes binary action
+// bound argument tuple, open argument tuple and gives the return type
+
+template<class Action, class Bound, class Open> class binary_rt {
+  private:
+    typedef typename
+      detail::deduce_argument_types<Bound, Open>::type rets_t;      
+  public:
+    typedef typename return_type_2_prot<
+      Action,  
+      typename detail::element_or_null<0, rets_t>::type,
+      typename detail::element_or_null<1, rets_t>::type
+    >::type type;
+};
+
+
+  // same for unary actions
+template<class Action, class Bound, class Open> class unary_rt {
+  private:
+    typedef typename
+      detail::deduce_argument_types<Bound, Open>::type rets_t;      
+  public:
+    typedef typename return_type_1_prot<
+      Action,  
+      typename detail::element_or_null<0, rets_t>::type
+    >::type type;
+};
+
+
+} // end detail
+
+// Specialization for logical and (to preserve shortcircuiting)
+// this could be done with a macro as the others, code used to be different
+template<class Args>
+class lambda_functor_base<logical_action<and_action>, Args> {
+public:
+  Args args;
+public:
+  explicit lambda_functor_base(const Args& a) : args(a) {}
+
+  template<class RET, CALL_TEMPLATE_ARGS>
+  RET call(CALL_FORMAL_ARGS) const {
+    return detail::select(ndnboost::tuples::get<0>(args), CALL_ACTUAL_ARGS) && 
+           detail::select(ndnboost::tuples::get<1>(args), CALL_ACTUAL_ARGS); 
+  }
+  template<class SigArgs> struct sig { 
+    typedef typename
+      detail::binary_rt<logical_action<and_action>, Args, SigArgs>::type type;
+  };      
+};  
+
+// Specialization for logical or (to preserve shortcircuiting)
+// this could be done with a macro as the others, code used to be different
+template<class Args>
+class lambda_functor_base<logical_action< or_action>, Args> {
+public:
+  Args args;
+public:
+  explicit lambda_functor_base(const Args& a) : args(a) {}
+
+  template<class RET, CALL_TEMPLATE_ARGS>
+  RET call(CALL_FORMAL_ARGS) const {
+    return detail::select(ndnboost::tuples::get<0>(args), CALL_ACTUAL_ARGS) || 
+           detail::select(ndnboost::tuples::get<1>(args), CALL_ACTUAL_ARGS); 
+  }
+
+  template<class SigArgs> struct sig { 
+    typedef typename
+      detail::binary_rt<logical_action<or_action>, Args, SigArgs>::type type;
+  };      
+};  
+
+// Specialization for subscript
+template<class Args>
+class lambda_functor_base<other_action<subscript_action>, Args> {
+public:
+  Args args;
+public:
+  explicit lambda_functor_base(const Args& a) : args(a) {}
+
+  template<class RET, CALL_TEMPLATE_ARGS>
+  RET call(CALL_FORMAL_ARGS) const {
+    return detail::select(ndnboost::tuples::get<0>(args), CALL_ACTUAL_ARGS) 
+           [detail::select(ndnboost::tuples::get<1>(args), CALL_ACTUAL_ARGS)]; 
+  }
+
+  template<class SigArgs> struct sig { 
+    typedef typename
+      detail::binary_rt<other_action<subscript_action>, Args, SigArgs>::type 
+        type;
+  };      
+};  
+
+
+#define BOOST_LAMBDA_BINARY_ACTION(SYMBOL, ACTION_CLASS)  \
+template<class Args>                                                      \
+class lambda_functor_base<ACTION_CLASS, Args> {                           \
+public:                                                                   \
+  Args args;                                                              \
+public:                                                                   \
+  explicit lambda_functor_base(const Args& a) : args(a) {}                \
+                                                                          \
+  template<class RET, CALL_TEMPLATE_ARGS>                                 \
+  RET call(CALL_FORMAL_ARGS) const {                                      \
+    return detail::select(ndnboost::tuples::get<0>(args), CALL_ACTUAL_ARGS)  \
+           SYMBOL                                                         \
+           detail::select(ndnboost::tuples::get<1>(args), CALL_ACTUAL_ARGS); \
+  }                                                                       \
+  template<class SigArgs> struct sig {                                    \
+    typedef typename                                                      \
+      detail::binary_rt<ACTION_CLASS, Args, SigArgs>::type type;          \
+  };                                                                      \
+};  
+
+#define BOOST_LAMBDA_PREFIX_UNARY_ACTION(SYMBOL, ACTION_CLASS)            \
+template<class Args>                                                      \
+class lambda_functor_base<ACTION_CLASS, Args> {                           \
+public:                                                                   \
+  Args args;                                                              \
+public:                                                                   \
+  explicit lambda_functor_base(const Args& a) : args(a) {}                \
+                                                                          \
+  template<class RET, CALL_TEMPLATE_ARGS>                                 \
+  RET call(CALL_FORMAL_ARGS) const {                                      \
+    return SYMBOL                                                         \
+           detail::select(ndnboost::tuples::get<0>(args), CALL_ACTUAL_ARGS); \
+  }                                                                       \
+  template<class SigArgs> struct sig {                                    \
+    typedef typename                                                      \
+      detail::unary_rt<ACTION_CLASS, Args, SigArgs>::type type;           \
+  };                                                                      \
+};  
+
+#define BOOST_LAMBDA_POSTFIX_UNARY_ACTION(SYMBOL, ACTION_CLASS)           \
+template<class Args>                                                      \
+class lambda_functor_base<ACTION_CLASS, Args> {                           \
+public:                                                                   \
+  Args args;                                                              \
+public:                                                                   \
+  explicit lambda_functor_base(const Args& a) : args(a) {}                \
+                                                                          \
+  template<class RET, CALL_TEMPLATE_ARGS>                                 \
+  RET call(CALL_FORMAL_ARGS) const {                                      \
+    return                                                                \
+    detail::select(ndnboost::tuples::get<0>(args), CALL_ACTUAL_ARGS) SYMBOL; \
+  }                                                                       \
+  template<class SigArgs> struct sig {                                    \
+    typedef typename                                                      \
+      detail::unary_rt<ACTION_CLASS, Args, SigArgs>::type type;           \
+  };                                                                      \
+};  
+
+BOOST_LAMBDA_BINARY_ACTION(+,arithmetic_action<plus_action>)
+BOOST_LAMBDA_BINARY_ACTION(-,arithmetic_action<minus_action>)
+BOOST_LAMBDA_BINARY_ACTION(*,arithmetic_action<multiply_action>)
+BOOST_LAMBDA_BINARY_ACTION(/,arithmetic_action<divide_action>)
+BOOST_LAMBDA_BINARY_ACTION(%,arithmetic_action<remainder_action>)
+
+BOOST_LAMBDA_BINARY_ACTION(<<,bitwise_action<leftshift_action>)
+BOOST_LAMBDA_BINARY_ACTION(>>,bitwise_action<rightshift_action>)
+BOOST_LAMBDA_BINARY_ACTION(&,bitwise_action<and_action>)
+BOOST_LAMBDA_BINARY_ACTION(|,bitwise_action<or_action>)
+BOOST_LAMBDA_BINARY_ACTION(^,bitwise_action<xor_action>)
+
+BOOST_LAMBDA_BINARY_ACTION(<,relational_action<less_action>)
+BOOST_LAMBDA_BINARY_ACTION(>,relational_action<greater_action>)
+BOOST_LAMBDA_BINARY_ACTION(<=,relational_action<lessorequal_action>)
+BOOST_LAMBDA_BINARY_ACTION(>=,relational_action<greaterorequal_action>)
+BOOST_LAMBDA_BINARY_ACTION(==,relational_action<equal_action>)
+BOOST_LAMBDA_BINARY_ACTION(!=,relational_action<notequal_action>)
+
+BOOST_LAMBDA_BINARY_ACTION(+=,arithmetic_assignment_action<plus_action>)
+BOOST_LAMBDA_BINARY_ACTION(-=,arithmetic_assignment_action<minus_action>)
+BOOST_LAMBDA_BINARY_ACTION(*=,arithmetic_assignment_action<multiply_action>)
+BOOST_LAMBDA_BINARY_ACTION(/=,arithmetic_assignment_action<divide_action>)
+BOOST_LAMBDA_BINARY_ACTION(%=,arithmetic_assignment_action<remainder_action>)
+
+BOOST_LAMBDA_BINARY_ACTION(<<=,bitwise_assignment_action<leftshift_action>)
+BOOST_LAMBDA_BINARY_ACTION(>>=,bitwise_assignment_action<rightshift_action>)
+BOOST_LAMBDA_BINARY_ACTION(&=,bitwise_assignment_action<and_action>)
+BOOST_LAMBDA_BINARY_ACTION(|=,bitwise_assignment_action<or_action>)
+BOOST_LAMBDA_BINARY_ACTION(^=,bitwise_assignment_action<xor_action>)
+
+BOOST_LAMBDA_BINARY_ACTION(=,other_action< assignment_action>)
+
+
+BOOST_LAMBDA_PREFIX_UNARY_ACTION(+, unary_arithmetic_action<plus_action>)
+BOOST_LAMBDA_PREFIX_UNARY_ACTION(-, unary_arithmetic_action<minus_action>)
+BOOST_LAMBDA_PREFIX_UNARY_ACTION(~, bitwise_action<not_action>)
+BOOST_LAMBDA_PREFIX_UNARY_ACTION(!, logical_action<not_action>)
+BOOST_LAMBDA_PREFIX_UNARY_ACTION(++, pre_increment_decrement_action<increment_action>)
+BOOST_LAMBDA_PREFIX_UNARY_ACTION(--, pre_increment_decrement_action<decrement_action>)
+
+BOOST_LAMBDA_PREFIX_UNARY_ACTION(&,other_action<addressof_action>)
+BOOST_LAMBDA_PREFIX_UNARY_ACTION(*,other_action<contentsof_action>)
+
+BOOST_LAMBDA_POSTFIX_UNARY_ACTION(++, post_increment_decrement_action<increment_action>)
+BOOST_LAMBDA_POSTFIX_UNARY_ACTION(--, post_increment_decrement_action<decrement_action>)
+
+
+#undef BOOST_LAMBDA_POSTFIX_UNARY_ACTION
+#undef BOOST_LAMBDA_PREFIX_UNARY_ACTION
+#undef BOOST_LAMBDA_BINARY_ACTION
+
+} // namespace lambda
+} // namespace ndnboost
+
+#endif
+
+
+
+
+
+
+
+
+
+
diff --git a/ndnboost/lambda/detail/operator_return_type_traits.hpp b/ndnboost/lambda/detail/operator_return_type_traits.hpp
new file mode 100644
index 0000000..0ee927b
--- /dev/null
+++ b/ndnboost/lambda/detail/operator_return_type_traits.hpp
@@ -0,0 +1,917 @@
+//  operator_return_type_traits.hpp -- Boost Lambda Library ------------------
+
+// Copyright (C) 1999, 2000 Jaakko Jarvi (jaakko.jarvi@cs.utu.fi)
+//
+// Distributed under the Boost Software License, Version 1.0. (See
+// accompanying file LICENSE_1_0.txt or copy at
+// http://www.boost.org/LICENSE_1_0.txt)
+//
+// For more information, see www.boost.org
+
+#ifndef BOOST_LAMBDA_OPERATOR_RETURN_TYPE_TRAITS_HPP
+#define BOOST_LAMBDA_OPERATOR_RETURN_TYPE_TRAITS_HPP
+
+#include "ndnboost/lambda/detail/is_instance_of.hpp"
+#include "ndnboost/type_traits/same_traits.hpp"
+
+#include "ndnboost/indirect_reference.hpp"
+#include "ndnboost/detail/container_fwd.hpp"
+
+#include <cstddef> // needed for the ptrdiff_t
+#include <iosfwd>  // for istream and ostream
+
+#include <iterator> // needed for operator&
+
+namespace ndnboost { 
+namespace lambda {
+namespace detail {
+
+// -- general helper templates for type deduction ------------------
+
+// Much of the type deduction code for standard arithmetic types from Gary Powell
+
+template <class A> struct promote_code { static const int value = -1; };
+// this means that a code is not defined for A
+
+// -- the next 5 types are needed in if_then_else_return 
+// the promotion order is not important, but they must have distinct values.
+template <> struct promote_code<bool> { static const int value = 10; };
+template <> struct promote_code<char> { static const int value = 20; };
+template <> struct promote_code<unsigned char> { static const int value = 30; };
+template <> struct promote_code<signed char> { static const int value = 40; };
+template <> struct promote_code<short int> { static const int value = 50; };
+// ----------
+
+template <> struct promote_code<int> { static const int value = 100; };
+template <> struct promote_code<unsigned int> { static const int value = 200; };
+template <> struct promote_code<long> { static const int value = 300; };
+template <> struct promote_code<unsigned long> { static const int value = 400; };
+
+template <> struct promote_code<float> { static const int value = 500; };
+template <> struct promote_code<double> { static const int value = 600; };
+template <> struct promote_code<long double> { static const int value = 700; };
+
+// TODO: wchar_t
+
+// forward delcaration of complex.
+
+} // namespace detail
+} // namespace lambda 
+} // namespace ndnboost
+
+namespace ndnboost { 
+namespace lambda {
+namespace detail {
+
+template <> struct promote_code< std::complex<float> > { static const int value = 800; };
+template <> struct promote_code< std::complex<double> > { static const int value = 900; };
+template <> struct promote_code< std::complex<long double> > { static const int value = 1000; };
+
+// -- int promotion -------------------------------------------
+template <class T> struct promote_to_int { typedef T type; };
+
+template <> struct promote_to_int<bool> { typedef int type; };
+template <> struct promote_to_int<char> { typedef int type; };
+template <> struct promote_to_int<unsigned char> { typedef int type; };
+template <> struct promote_to_int<signed char> { typedef int type; };
+template <> struct promote_to_int<short int> { typedef int type; };
+
+// The unsigned short int promotion rule is this:
+// unsigned short int to signed int if a signed int can hold all values 
+// of unsigned short int, otherwise go to unsigned int.
+template <> struct promote_to_int<unsigned short int>
+{ 
+        typedef
+                detail::IF<sizeof(int) <= sizeof(unsigned short int),        
+// I had the logic reversed but ">" messes up the parsing.
+                unsigned int,
+                int>::RET type; 
+};
+
+
+// TODO: think, should there be default behaviour for non-standard types?
+
+} // namespace detail
+
+// ------------------------------------------ 
+// Unary actions ----------------------------
+// ------------------------------------------ 
+
+template<class Act, class A>
+struct plain_return_type_1 {
+  typedef detail::unspecified type;
+};
+
+
+
+template<class Act, class A>
+struct plain_return_type_1<unary_arithmetic_action<Act>, A> {
+  typedef A type;
+};
+
+template<class Act, class A> 
+struct return_type_1<unary_arithmetic_action<Act>, A> { 
+  typedef 
+    typename plain_return_type_1<
+      unary_arithmetic_action<Act>,
+      typename detail::remove_reference_and_cv<A>::type
+    >::type type;
+};
+
+
+template<class A>
+struct plain_return_type_1<bitwise_action<not_action>, A> {
+  typedef A type;
+};
+
+// bitwise not, operator~()
+template<class A> struct return_type_1<bitwise_action<not_action>, A> {
+  typedef 
+    typename plain_return_type_1<
+      bitwise_action<not_action>,
+      typename detail::remove_reference_and_cv<A>::type
+    >::type type;
+};
+
+
+// prefix increment and decrement operators return 
+// their argument by default as a non-const reference
+template<class Act, class A> 
+struct plain_return_type_1<pre_increment_decrement_action<Act>, A> {
+  typedef A& type;
+};
+
+template<class Act, class A> 
+struct return_type_1<pre_increment_decrement_action<Act>, A> {
+  typedef 
+    typename plain_return_type_1<
+      pre_increment_decrement_action<Act>,
+      typename detail::remove_reference_and_cv<A>::type
+    >::type type;
+};
+
+// post decrement just returns the same plain type.
+template<class Act, class A>
+struct plain_return_type_1<post_increment_decrement_action<Act>, A> {
+  typedef A type;
+};
+
+template<class Act, class A> 
+struct return_type_1<post_increment_decrement_action<Act>, A> 
+{ 
+  typedef 
+    typename plain_return_type_1<
+      post_increment_decrement_action<Act>,
+      typename detail::remove_reference_and_cv<A>::type
+    >::type type;
+};
+
+// logical not, operator!()
+template<class A> 
+struct plain_return_type_1<logical_action<not_action>, A> {
+  typedef bool type;
+};
+
+template<class A>
+struct return_type_1<logical_action<not_action>, A> {
+  typedef 
+    typename plain_return_type_1<
+      logical_action<not_action>,
+      typename detail::remove_reference_and_cv<A>::type
+    >::type type;
+};
+
+// address of action ---------------------------------------
+
+
+template<class A> 
+struct return_type_1<other_action<addressof_action>, A> { 
+  typedef 
+    typename plain_return_type_1<
+      other_action<addressof_action>, 
+      typename detail::remove_reference_and_cv<A>::type
+    >::type type1;
+
+  // If no user defined specialization for A, then return the
+  // cv qualified pointer to A
+  typedef typename detail::IF<
+    ndnboost::is_same<type1, detail::unspecified>::value, 
+    typename ndnboost::remove_reference<A>::type*,
+    type1
+  >::RET type;
+};
+
+// contentsof action ------------------------------------
+
+// TODO: this deduction may lead to fail directly, 
+// (if A has no specialization for iterator_traits and has no
+// typedef A::reference.
+// There is no easy way around this, cause there doesn't seem to be a way
+// to test whether a class is an iterator or not.
+ 
+// The default works with std::iterators.
+
+namespace detail {
+
+  // A is a nonreference type
+template <class A> struct contentsof_type {
+  typedef typename ndnboost::indirect_reference<A>::type type; 
+};
+
+  // this is since the nullary () in lambda_functor is always instantiated
+template <> struct contentsof_type<null_type> {
+  typedef detail::unspecified type;
+};
+
+
+template <class A> struct contentsof_type<const A> {
+  typedef typename contentsof_type<A>::type type;
+};
+
+template <class A> struct contentsof_type<volatile A> {
+  typedef typename contentsof_type<A>::type type;
+};
+
+template <class A> struct contentsof_type<const volatile A> {
+  typedef typename contentsof_type<A>::type type;
+};
+
+  // standard iterator traits should take care of the pointer types 
+  // but just to be on the safe side, we have the specializations here:
+  // these work even if A is cv-qualified.
+template <class A> struct contentsof_type<A*> {
+  typedef A& type;
+};
+template <class A> struct contentsof_type<A* const> {
+  typedef A& type;
+};
+template <class A> struct contentsof_type<A* volatile> {
+  typedef A& type;
+};
+template <class A> struct contentsof_type<A* const volatile> {
+  typedef A& type;
+};
+
+template<class A, int N> struct contentsof_type<A[N]> { 
+  typedef A& type; 
+};
+template<class A, int N> struct contentsof_type<const A[N]> { 
+  typedef const A& type; 
+};
+template<class A, int N> struct contentsof_type<volatile A[N]> { 
+  typedef volatile A& type; 
+};
+template<class A, int N> struct contentsof_type<const volatile A[N]> { 
+  typedef const volatile A& type; 
+};
+
+
+
+
+
+} // end detail
+
+template<class A> 
+struct return_type_1<other_action<contentsof_action>, A> { 
+
+  typedef 
+    typename plain_return_type_1<
+      other_action<contentsof_action>, 
+      typename detail::remove_reference_and_cv<A>::type
+    >::type type1;
+
+  // If no user defined specialization for A, then return the
+  // cv qualified pointer to A
+  typedef typename 
+  detail::IF_type<
+    ndnboost::is_same<type1, detail::unspecified>::value, 
+    detail::contentsof_type<
+      typename ndnboost::remove_reference<A>::type
+    >,
+    detail::identity_mapping<type1>
+  >::type type;
+};
+
+
+// ------------------------------------------------------------------
+// binary actions ---------------------------------------------------
+// ------------------------------------------------------------------
+
+// here the default case is: no user defined versions:
+template <class Act, class A, class B>
+struct plain_return_type_2 {
+  typedef detail::unspecified type; 
+};
+
+namespace detail {
+
+// error classes
+class illegal_pointer_arithmetic{};
+
+// pointer arithmetic type deductions ----------------------
+// value = false means that this is not a pointer arithmetic case
+// value = true means, that this can be a pointer arithmetic case, but not necessarily is
+// This means, that for user defined operators for pointer types, say for some operator+(X, *Y),
+// the deductions must be coded at an earliel level (return_type_2).
+
+template<class Act, class A, class B> 
+struct pointer_arithmetic_traits { static const bool value = false; };
+
+template<class A, class B> 
+struct pointer_arithmetic_traits<plus_action, A, B> { 
+
+  typedef typename 
+    array_to_pointer<typename ndnboost::remove_reference<A>::type>::type AP;
+  typedef typename 
+    array_to_pointer<typename ndnboost::remove_reference<B>::type>::type BP;
+
+  static const bool is_pointer_A = ndnboost::is_pointer<AP>::value;
+  static const bool is_pointer_B = ndnboost::is_pointer<BP>::value;  
+
+  static const bool value = is_pointer_A || is_pointer_B;
+
+  // can't add two pointers.
+  // note, that we do not check wether the other type is valid for 
+  // addition with a pointer.
+  // the compiler will catch it in the apply function
+
+  typedef typename 
+  detail::IF<
+    is_pointer_A && is_pointer_B, 
+      detail::return_type_deduction_failure<
+        detail::illegal_pointer_arithmetic
+      >,
+      typename detail::IF<is_pointer_A, AP, BP>::RET
+  >::RET type; 
+
+};
+
+template<class A, class B> 
+struct pointer_arithmetic_traits<minus_action, A, B> { 
+  typedef typename 
+    array_to_pointer<typename ndnboost::remove_reference<A>::type>::type AP;
+  typedef typename 
+    array_to_pointer<typename ndnboost::remove_reference<B>::type>::type BP;
+
+  static const bool is_pointer_A = ndnboost::is_pointer<AP>::value;
+  static const bool is_pointer_B = ndnboost::is_pointer<BP>::value;  
+
+  static const bool value = is_pointer_A || is_pointer_B;
+
+  static const bool same_pointer_type =
+    is_pointer_A && is_pointer_B && 
+    ndnboost::is_same<
+      typename ndnboost::remove_const<
+        typename ndnboost::remove_pointer<
+          typename ndnboost::remove_const<AP>::type
+        >::type
+      >::type,
+      typename ndnboost::remove_const<
+        typename ndnboost::remove_pointer<
+          typename ndnboost::remove_const<BP>::type
+        >::type
+      >::type
+    >::value;
+
+  // ptr - ptr has type ptrdiff_t
+  // note, that we do not check if, in ptr - B, B is 
+  // valid for subtraction with a pointer.
+  // the compiler will catch it in the apply function
+
+  typedef typename 
+  detail::IF<
+    same_pointer_type, const std::ptrdiff_t,
+    typename detail::IF<
+      is_pointer_A, 
+      AP, 
+      detail::return_type_deduction_failure<detail::illegal_pointer_arithmetic>
+    >::RET
+  >::RET type; 
+};
+
+} // namespace detail
+   
+// -- arithmetic actions ---------------------------------------------
+
+namespace detail {
+   
+template<bool is_pointer_arithmetic, class Act, class A, class B> 
+struct return_type_2_arithmetic_phase_1;
+
+template<class A, class B> struct return_type_2_arithmetic_phase_2;
+template<class A, class B> struct return_type_2_arithmetic_phase_3;
+
+} // namespace detail
+  
+
+// drop any qualifiers from the argument types within arithmetic_action
+template<class A, class B, class Act> 
+struct return_type_2<arithmetic_action<Act>, A, B>
+{
+  typedef typename detail::remove_reference_and_cv<A>::type plain_A;
+  typedef typename detail::remove_reference_and_cv<B>::type plain_B;
+
+  typedef typename 
+    plain_return_type_2<arithmetic_action<Act>, plain_A, plain_B>::type type1;
+  
+  // if user defined return type, do not enter the whole arithmetic deductions
+  typedef typename 
+    detail::IF_type<
+      ndnboost::is_same<type1, detail::unspecified>::value, 
+      detail::return_type_2_arithmetic_phase_1<
+         detail::pointer_arithmetic_traits<Act, A, B>::value, Act, A, B
+      >,
+      plain_return_type_2<arithmetic_action<Act>, plain_A, plain_B>
+    >::type type;
+};
+
+namespace detail {
+   
+// perform integral promotion, no pointer arithmetic
+template<bool is_pointer_arithmetic, class Act, class A, class B> 
+struct return_type_2_arithmetic_phase_1
+{
+  typedef typename 
+    return_type_2_arithmetic_phase_2<
+      typename remove_reference_and_cv<A>::type,
+      typename remove_reference_and_cv<B>::type
+    >::type type;
+};
+
+// pointer_arithmetic
+template<class Act, class A, class B> 
+struct return_type_2_arithmetic_phase_1<true, Act, A, B>
+{
+  typedef typename 
+    pointer_arithmetic_traits<Act, A, B>::type type;
+};
+
+template<class A, class B>
+struct return_type_2_arithmetic_phase_2 {
+  typedef typename
+    return_type_2_arithmetic_phase_3<
+      typename promote_to_int<A>::type, 
+      typename promote_to_int<B>::type
+    >::type type;
+};
+
+// specialization for unsigned int.
+// We only have to do these two specialization because the value promotion will
+// take care of the other cases.
+// The unsigned int promotion rule is this:
+// unsigned int to long if a long can hold all values of unsigned int,
+// otherwise go to unsigned long.
+
+// struct so I don't have to type this twice.
+struct promotion_of_unsigned_int
+{
+        typedef
+        detail::IF<sizeof(long) <= sizeof(unsigned int),        
+                unsigned long,
+                long>::RET type; 
+};
+
+template<>
+struct return_type_2_arithmetic_phase_2<unsigned int, long>
+{
+        typedef promotion_of_unsigned_int::type type;
+};
+template<>
+struct return_type_2_arithmetic_phase_2<long, unsigned int>
+{
+        typedef promotion_of_unsigned_int::type type;
+};
+
+
+template<class A, class B> struct return_type_2_arithmetic_phase_3 { 
+   enum { promote_code_A_value = promote_code<A>::value,
+         promote_code_B_value = promote_code<B>::value }; // enums for KCC
+  typedef typename
+    detail::IF<
+      promote_code_A_value == -1 || promote_code_B_value == -1,
+      detail::return_type_deduction_failure<return_type_2_arithmetic_phase_3>,
+      typename detail::IF<
+        ((int)promote_code_A_value > (int)promote_code_B_value), 
+        A, 
+        B
+      >::RET
+    >::RET type;                    
+};
+
+} // namespace detail
+
+// --  bitwise actions -------------------------------------------
+// note: for integral types deuduction is similar to arithmetic actions. 
+
+// drop any qualifiers from the argument types within arithmetic action
+template<class A, class B, class Act> 
+struct return_type_2<bitwise_action<Act>, A, B>
+{
+
+  typedef typename detail::remove_reference_and_cv<A>::type plain_A;
+  typedef typename detail::remove_reference_and_cv<B>::type plain_B;
+
+  typedef typename 
+    plain_return_type_2<bitwise_action<Act>, plain_A, plain_B>::type type1;
+  
+  // if user defined return type, do not enter type deductions
+  typedef typename 
+    detail::IF_type<
+      ndnboost::is_same<type1, detail::unspecified>::value, 
+      return_type_2<arithmetic_action<plus_action>, A, B>,
+      plain_return_type_2<bitwise_action<Act>, plain_A, plain_B>
+    >::type type;
+
+  // plus_action is just a random pick, has to be a concrete instance
+
+  // TODO: This check is only valid for built-in types, overloaded types might
+  // accept floating point operators
+
+  // bitwise operators not defined for floating point types
+  // these test are not strictly needed here, since the error will be caught in
+  // the apply function
+  BOOST_STATIC_ASSERT(!(ndnboost::is_float<plain_A>::value && ndnboost::is_float<plain_B>::value));
+
+};
+
+namespace detail {
+
+#ifdef BOOST_NO_TEMPLATED_STREAMS
+
+template<class A, class B>
+struct leftshift_type {
+
+  typedef typename detail::IF<
+    ndnboost::is_convertible<
+      typename ndnboost::remove_reference<A>::type*,
+      std::ostream*
+    >::value,
+    std::ostream&, 
+    typename detail::remove_reference_and_cv<A>::type
+  >::RET type;
+};
+
+template<class A, class B>
+struct rightshift_type {
+
+  typedef typename detail::IF<
+
+    ndnboost::is_convertible<
+      typename ndnboost::remove_reference<A>::type*,
+      std::istream*
+    >::value, 
+    std::istream&,
+    typename detail::remove_reference_and_cv<A>::type
+  >::RET type;
+};
+
+#else
+
+template <class T> struct get_ostream_type {
+  typedef std::basic_ostream<typename T::char_type, 
+                             typename T::traits_type>& type;
+};
+
+template <class T> struct get_istream_type {
+  typedef std::basic_istream<typename T::char_type, 
+                             typename T::traits_type>& type;
+};
+
+template<class A, class B>
+struct leftshift_type {
+private:
+  typedef typename ndnboost::remove_reference<A>::type plainA;
+public:
+  typedef typename detail::IF_type<
+    is_instance_of_2<plainA, std::basic_ostream>::value, 
+    get_ostream_type<plainA>, //reference to the stream 
+    detail::remove_reference_and_cv<A>
+  >::type type;
+};
+
+template<class A, class B>
+struct rightshift_type {
+private:
+  typedef typename ndnboost::remove_reference<A>::type plainA;
+public:
+  typedef typename detail::IF_type<
+    is_instance_of_2<plainA, std::basic_istream>::value, 
+    get_istream_type<plainA>, //reference to the stream 
+    detail::remove_reference_and_cv<A>
+  >::type type;
+};
+
+
+#endif
+
+} // end detail
+
+// ostream
+template<class A, class B> 
+struct return_type_2<bitwise_action<leftshift_action>, A, B>
+{
+  typedef typename detail::remove_reference_and_cv<A>::type plain_A;
+  typedef typename detail::remove_reference_and_cv<B>::type plain_B;
+
+  typedef typename 
+    plain_return_type_2<bitwise_action<leftshift_action>, plain_A, plain_B>::type type1;
+  
+  // if user defined return type, do not enter type deductions
+  typedef typename 
+    detail::IF_type<
+      ndnboost::is_same<type1, detail::unspecified>::value, 
+      detail::leftshift_type<A, B>,
+      plain_return_type_2<bitwise_action<leftshift_action>, plain_A, plain_B>
+    >::type type;
+};
+
+// istream
+template<class A, class B> 
+struct return_type_2<bitwise_action<rightshift_action>, A, B>
+{
+  typedef typename detail::remove_reference_and_cv<A>::type plain_A;
+  typedef typename detail::remove_reference_and_cv<B>::type plain_B;
+
+  typedef typename 
+    plain_return_type_2<bitwise_action<rightshift_action>, plain_A, plain_B>::type type1;
+  
+  // if user defined return type, do not enter type deductions
+  typedef typename 
+    detail::IF_type<
+      ndnboost::is_same<type1, detail::unspecified>::value, 
+      detail::rightshift_type<A, B>,
+      plain_return_type_2<bitwise_action<rightshift_action>, plain_A, plain_B>
+    >::type type;
+};
+
+// -- logical actions ----------------------------------------
+// always bool
+// NOTE: this may not be true for some weird user-defined types,
+template<class A, class B, class Act> 
+struct plain_return_type_2<logical_action<Act>, A, B> { 
+  typedef bool type; 
+};
+
+template<class A, class B, class Act> 
+struct return_type_2<logical_action<Act>, A, B> { 
+
+  typedef typename detail::remove_reference_and_cv<A>::type plain_A;
+  typedef typename detail::remove_reference_and_cv<B>::type plain_B;
+
+  typedef typename 
+    plain_return_type_2<logical_action<Act>, plain_A, plain_B>::type type;
+  
+};
+
+
+// -- relational actions ----------------------------------------
+// always bool
+// NOTE: this may not be true for some weird user-defined types,
+template<class A, class B, class Act> 
+struct plain_return_type_2<relational_action<Act>, A, B> { 
+  typedef bool type; 
+};
+
+template<class A, class B, class Act> 
+struct return_type_2<relational_action<Act>, A, B> { 
+
+  typedef typename detail::remove_reference_and_cv<A>::type plain_A;
+  typedef typename detail::remove_reference_and_cv<B>::type plain_B;
+
+  typedef typename 
+    plain_return_type_2<relational_action<Act>, plain_A, plain_B>::type type; 
+};
+
+// Assingment actions -----------------------------------------------
+// return type is the type of the first argument as reference
+
+// note that cv-qualifiers are preserved.
+// Yes, assignment operator can be const!
+
+// NOTE: this may not be true for some weird user-defined types,
+
+template<class A, class B, class Act> 
+struct return_type_2<arithmetic_assignment_action<Act>, A, B> { 
+
+  typedef typename detail::remove_reference_and_cv<A>::type plain_A;
+  typedef typename detail::remove_reference_and_cv<B>::type plain_B;
+
+  typedef typename 
+    plain_return_type_2<
+      arithmetic_assignment_action<Act>, plain_A, plain_B
+    >::type type1;
+  
+  typedef typename 
+    detail::IF<
+      ndnboost::is_same<type1, detail::unspecified>::value, 
+      typename ndnboost::add_reference<A>::type,
+      type1
+    >::RET type;
+};
+
+template<class A, class B, class Act> 
+struct return_type_2<bitwise_assignment_action<Act>, A, B> { 
+
+  typedef typename detail::remove_reference_and_cv<A>::type plain_A;
+  typedef typename detail::remove_reference_and_cv<B>::type plain_B;
+
+  typedef typename 
+    plain_return_type_2<
+      bitwise_assignment_action<Act>, plain_A, plain_B
+    >::type type1;
+  
+  typedef typename 
+    detail::IF<
+      ndnboost::is_same<type1, detail::unspecified>::value, 
+      typename ndnboost::add_reference<A>::type,
+      type1
+    >::RET type;
+};
+
+template<class A, class B> 
+struct return_type_2<other_action<assignment_action>, A, B> { 
+  typedef typename detail::remove_reference_and_cv<A>::type plain_A;
+  typedef typename detail::remove_reference_and_cv<B>::type plain_B;
+
+  typedef typename 
+    plain_return_type_2<
+      other_action<assignment_action>, plain_A, plain_B
+    >::type type1;
+  
+  typedef typename 
+    detail::IF<
+      ndnboost::is_same<type1, detail::unspecified>::value, 
+      typename ndnboost::add_reference<A>::type,
+      type1
+    >::RET type;
+};
+
+// -- other actions ----------------------------------------
+
+// comma action ----------------------------------
+// Note: this may not be true for some weird user-defined types,
+
+// NOTE! This only tries the plain_return_type_2 layer and gives
+// detail::unspecified as default. If no such specialization is found, the 
+// type rule in the spcecialization of the return_type_2_prot is used
+// to give the type of the right argument (which can be a reference too)
+// (The built in operator, can return a l- or rvalue).
+template<class A, class B> 
+struct return_type_2<other_action<comma_action>, A, B> { 
+
+  typedef typename detail::remove_reference_and_cv<A>::type plain_A;
+  typedef typename detail::remove_reference_and_cv<B>::type plain_B;
+
+  typedef typename 
+    plain_return_type_2<
+      other_action<comma_action>, plain_A, plain_B
+    >::type type;
+  };
+
+// subscript action -----------------------------------------------
+
+
+namespace detail {
+  // A and B are nonreference types
+template <class A, class B> struct subscript_type {
+  typedef detail::unspecified type; 
+};
+
+template <class A, class B> struct subscript_type<A*, B> {
+  typedef A& type;
+};
+template <class A, class B> struct subscript_type<A* const, B> {
+  typedef A& type;
+};
+template <class A, class B> struct subscript_type<A* volatile, B> {
+  typedef A& type;
+};
+template <class A, class B> struct subscript_type<A* const volatile, B> {
+  typedef A& type;
+};
+
+
+template<class A, class B, int N> struct subscript_type<A[N], B> { 
+  typedef A& type; 
+};
+
+  // these 3 specializations are needed to make gcc <3 happy
+template<class A, class B, int N> struct subscript_type<const A[N], B> { 
+  typedef const A& type; 
+};
+template<class A, class B, int N> struct subscript_type<volatile A[N], B> { 
+  typedef volatile A& type; 
+};
+template<class A, class B, int N> struct subscript_type<const volatile A[N], B> { 
+  typedef const volatile A& type; 
+};
+
+} // end detail
+
+template<class A, class B>
+struct return_type_2<other_action<subscript_action>, A, B> {
+
+  typedef typename detail::remove_reference_and_cv<A>::type plain_A;
+  typedef typename detail::remove_reference_and_cv<B>::type plain_B;
+
+  typedef typename ndnboost::remove_reference<A>::type nonref_A;
+  typedef typename ndnboost::remove_reference<B>::type nonref_B;
+
+  typedef typename 
+    plain_return_type_2<
+      other_action<subscript_action>, plain_A, plain_B
+    >::type type1;
+  
+  typedef typename 
+    detail::IF_type<
+      ndnboost::is_same<type1, detail::unspecified>::value, 
+      detail::subscript_type<nonref_A, nonref_B>,
+      plain_return_type_2<other_action<subscript_action>, plain_A, plain_B>
+    >::type type;
+
+};
+
+template<class Key, class T, class Cmp, class Allocator, class B> 
+struct plain_return_type_2<other_action<subscript_action>, std::map<Key, T, Cmp, Allocator>, B> { 
+  typedef T& type;
+  // T == std::map<Key, T, Cmp, Allocator>::mapped_type; 
+};
+
+template<class Key, class T, class Cmp, class Allocator, class B> 
+struct plain_return_type_2<other_action<subscript_action>, std::multimap<Key, T, Cmp, Allocator>, B> { 
+  typedef T& type;
+  // T == std::map<Key, T, Cmp, Allocator>::mapped_type; 
+};
+
+  // deque
+template<class T, class Allocator, class B> 
+struct plain_return_type_2<other_action<subscript_action>, std::deque<T, Allocator>, B> { 
+  typedef typename std::deque<T, Allocator>::reference type;
+};
+template<class T, class Allocator, class B> 
+struct plain_return_type_2<other_action<subscript_action>, const std::deque<T, Allocator>, B> { 
+  typedef typename std::deque<T, Allocator>::const_reference type;
+};
+
+  // vector
+template<class T, class Allocator, class B> 
+struct plain_return_type_2<other_action<subscript_action>, std::vector<T, Allocator>, B> { 
+  typedef typename std::vector<T, Allocator>::reference type;
+};
+template<class T, class Allocator, class B> 
+struct plain_return_type_2<other_action<subscript_action>, const std::vector<T, Allocator>, B> { 
+  typedef typename std::vector<T, Allocator>::const_reference type;
+};
+
+  // basic_string
+template<class Char, class Traits, class Allocator, class B> 
+struct plain_return_type_2<other_action<subscript_action>, std::basic_string<Char, Traits, Allocator>, B> { 
+  typedef typename std::basic_string<Char, Traits, Allocator>::reference type;
+};
+template<class Char, class Traits, class Allocator, class B> 
+struct plain_return_type_2<other_action<subscript_action>, const std::basic_string<Char, Traits, Allocator>, B> { 
+  typedef typename std::basic_string<Char, Traits, Allocator>::const_reference type;
+};
+
+template<class Char, class Traits, class Allocator> 
+struct plain_return_type_2<arithmetic_action<plus_action>,
+                           std::basic_string<Char, Traits, Allocator>,
+                           std::basic_string<Char, Traits, Allocator> > { 
+  typedef std::basic_string<Char, Traits, Allocator> type;
+};
+
+template<class Char, class Traits, class Allocator> 
+struct plain_return_type_2<arithmetic_action<plus_action>,
+                           const Char*,
+                           std::basic_string<Char, Traits, Allocator> > { 
+  typedef std::basic_string<Char, Traits, Allocator> type;
+};
+
+template<class Char, class Traits, class Allocator> 
+struct plain_return_type_2<arithmetic_action<plus_action>,
+                           std::basic_string<Char, Traits, Allocator>,
+                           const Char*> { 
+  typedef std::basic_string<Char, Traits, Allocator> type;
+};
+
+template<class Char, class Traits, class Allocator, std::size_t N> 
+struct plain_return_type_2<arithmetic_action<plus_action>,
+                           Char[N],
+                           std::basic_string<Char, Traits, Allocator> > { 
+  typedef std::basic_string<Char, Traits, Allocator> type;
+};
+
+template<class Char, class Traits, class Allocator, std::size_t N> 
+struct plain_return_type_2<arithmetic_action<plus_action>,
+                           std::basic_string<Char, Traits, Allocator>,
+                           Char[N]> { 
+  typedef std::basic_string<Char, Traits, Allocator> type;
+};
+
+
+} // namespace lambda
+} // namespace ndnboost
+
+#endif
+
+
diff --git a/ndnboost/lambda/detail/operators.hpp b/ndnboost/lambda/detail/operators.hpp
new file mode 100644
index 0000000..7c3bc8b
--- /dev/null
+++ b/ndnboost/lambda/detail/operators.hpp
@@ -0,0 +1,370 @@
+// Boost Lambda Library - operators.hpp --------------------------------------
+
+// Copyright (C) 1999, 2000 Jaakko Jarvi (jaakko.jarvi@cs.utu.fi)
+//
+// Distributed under the Boost Software License, Version 1.0. (See
+// accompanying file LICENSE_1_0.txt or copy at
+// http://www.boost.org/LICENSE_1_0.txt)
+//
+// For more information, see www.boost.org
+
+// ---------------------------------------------------------------
+
+#ifndef BOOST_LAMBDA_OPERATORS_HPP
+#define BOOST_LAMBDA_OPERATORS_HPP
+
+#include "ndnboost/lambda/detail/is_instance_of.hpp"
+
+namespace ndnboost { 
+namespace lambda {
+
+#if defined BOOST_LAMBDA_BE1
+#error "Multiple defines of BOOST_LAMBDA_BE1"
+#endif
+
+  // For all BOOSTA_LAMBDA_BE* macros:
+
+  // CONSTA must be either 'A' or 'const A'
+  // CONSTB must be either 'B' or 'const B'
+
+  // It is stupid to have the names A and B as macro arguments, but it avoids
+  // the need to pass in emtpy macro arguments, which gives warnings on some
+  // compilers
+
+#define BOOST_LAMBDA_BE1(OPER_NAME, ACTION, CONSTA, CONSTB, CONVERSION)      \
+template<class Arg, class B>                                                 \
+inline const                                                                 \
+lambda_functor<                                                              \
+  lambda_functor_base<                                                       \
+    ACTION,                                                                  \
+    tuple<lambda_functor<Arg>, typename const_copy_argument <CONSTB>::type>  \
+  >                                                                          \
+>                                                                            \
+OPER_NAME (const lambda_functor<Arg>& a, CONSTB& b) {                      \
+  return                                                                     \
+    lambda_functor_base<                                                     \
+      ACTION,                                                                \
+      tuple<lambda_functor<Arg>, typename const_copy_argument <CONSTB>::type>\
+    >                                                                        \
+   (tuple<lambda_functor<Arg>, typename const_copy_argument <CONSTB>::type>(a, b)); \
+}
+
+
+#if defined BOOST_LAMBDA_BE2
+#error "Multiple defines of BOOST_LAMBDA_BE2"
+#endif
+
+#define BOOST_LAMBDA_BE2(OPER_NAME, ACTION, CONSTA, CONSTB, CONVERSION)      \
+template<class A, class Arg>                                                 \
+inline const                                                                 \
+lambda_functor<                                                              \
+  lambda_functor_base<                                                       \
+    ACTION,                                                                  \
+    tuple<typename CONVERSION <CONSTA>::type, lambda_functor<Arg> >        \
+  >                                                                          \
+>                                                                            \
+OPER_NAME (CONSTA& a, const lambda_functor<Arg>& b) {                      \
+  return                                                                     \
+    lambda_functor_base<                                                     \
+      ACTION,                                                                \
+      tuple<typename CONVERSION <CONSTA>::type, lambda_functor<Arg> >      \
+    >                                                                        \
+  (tuple<typename CONVERSION <CONSTA>::type, lambda_functor<Arg> >(a, b)); \
+}
+
+
+#if defined BOOST_LAMBDA_BE3
+#error "Multiple defines of BOOST_LAMBDA_BE3"
+#endif
+
+#define BOOST_LAMBDA_BE3(OPER_NAME, ACTION, CONSTA, CONSTB, CONVERSION)    \
+template<class ArgA, class ArgB>                                           \
+inline const                                                               \
+lambda_functor<                                                            \
+  lambda_functor_base<                                                     \
+    ACTION,                                                                \
+    tuple<lambda_functor<ArgA>, lambda_functor<ArgB> >                     \
+  >                                                                        \
+>                                                                          \
+OPER_NAME (const lambda_functor<ArgA>& a, const lambda_functor<ArgB>& b) { \
+  return                                                                   \
+    lambda_functor_base<                                                   \
+      ACTION,                                                              \
+      tuple<lambda_functor<ArgA>, lambda_functor<ArgB> >                   \
+    >                                                                      \
+  (tuple<lambda_functor<ArgA>, lambda_functor<ArgB> >(a, b));              \
+}
+
+#if defined BOOST_LAMBDA_BE
+#error "Multiple defines of BOOST_LAMBDA_BE"
+#endif
+
+#define BOOST_LAMBDA_BE(OPER_NAME, ACTION, CONSTA, CONSTB, CONST_CONVERSION) \
+BOOST_LAMBDA_BE1(OPER_NAME, ACTION, CONSTA, CONSTB, CONST_CONVERSION)        \
+BOOST_LAMBDA_BE2(OPER_NAME, ACTION, CONSTA, CONSTB, CONST_CONVERSION)        \
+BOOST_LAMBDA_BE3(OPER_NAME, ACTION, CONSTA, CONSTB, CONST_CONVERSION)
+
+#define BOOST_LAMBDA_EMPTY() 
+
+BOOST_LAMBDA_BE(operator+, arithmetic_action<plus_action>, const A, const B, const_copy_argument)
+BOOST_LAMBDA_BE(operator-, arithmetic_action<minus_action>, const A, const B, const_copy_argument)
+BOOST_LAMBDA_BE(operator*, arithmetic_action<multiply_action>, const A, const B, const_copy_argument)
+BOOST_LAMBDA_BE(operator/, arithmetic_action<divide_action>, const A, const B, const_copy_argument)
+BOOST_LAMBDA_BE(operator%, arithmetic_action<remainder_action>, const A, const B, const_copy_argument)
+BOOST_LAMBDA_BE(operator<<, bitwise_action<leftshift_action>, const A, const B, const_copy_argument)
+BOOST_LAMBDA_BE(operator>>, bitwise_action<rightshift_action>, const A, const B, const_copy_argument)
+BOOST_LAMBDA_BE(operator&, bitwise_action<and_action>, const A, const B, const_copy_argument)
+BOOST_LAMBDA_BE(operator|, bitwise_action<or_action>, const A, const B, const_copy_argument)
+BOOST_LAMBDA_BE(operator^, bitwise_action<xor_action>, const A, const B, const_copy_argument)
+BOOST_LAMBDA_BE(operator&&, logical_action<and_action>, const A, const B, const_copy_argument)
+BOOST_LAMBDA_BE(operator||, logical_action<or_action>, const A, const B, const_copy_argument)
+BOOST_LAMBDA_BE(operator<, relational_action<less_action>, const A, const B, const_copy_argument)
+BOOST_LAMBDA_BE(operator>, relational_action<greater_action>, const A, const B, const_copy_argument)
+BOOST_LAMBDA_BE(operator<=, relational_action<lessorequal_action>, const A, const B, const_copy_argument)
+BOOST_LAMBDA_BE(operator>=, relational_action<greaterorequal_action>, const A, const B, const_copy_argument)
+BOOST_LAMBDA_BE(operator==, relational_action<equal_action>, const A, const B, const_copy_argument)
+BOOST_LAMBDA_BE(operator!=, relational_action<notequal_action>, const A, const B, const_copy_argument)
+
+BOOST_LAMBDA_BE(operator+=, arithmetic_assignment_action<plus_action>, A, const B, reference_argument)
+BOOST_LAMBDA_BE(operator-=, arithmetic_assignment_action<minus_action>, A, const B, reference_argument)
+BOOST_LAMBDA_BE(operator*=, arithmetic_assignment_action<multiply_action>, A, const B, reference_argument)
+BOOST_LAMBDA_BE(operator/=, arithmetic_assignment_action<divide_action>, A, const B, reference_argument)
+BOOST_LAMBDA_BE(operator%=, arithmetic_assignment_action<remainder_action>, A, const B, reference_argument)
+BOOST_LAMBDA_BE(operator<<=, bitwise_assignment_action<leftshift_action>, A, const B, reference_argument)
+BOOST_LAMBDA_BE(operator>>=, bitwise_assignment_action<rightshift_action>, A, const B, reference_argument)
+BOOST_LAMBDA_BE(operator&=, bitwise_assignment_action<and_action>, A, const B, reference_argument)
+BOOST_LAMBDA_BE(operator|=, bitwise_assignment_action<or_action>, A, const B, reference_argument)
+BOOST_LAMBDA_BE(operator^=, bitwise_assignment_action<xor_action>, A, const B, reference_argument)
+
+
+// A special trick for comma operator for correct preprocessing
+#if defined BOOST_LAMBDA_COMMA_OPERATOR_NAME
+#error "Multiple defines of BOOST_LAMBDA_COMMA_OPERATOR_NAME"
+#endif
+
+#define BOOST_LAMBDA_COMMA_OPERATOR_NAME operator,
+
+BOOST_LAMBDA_BE1(BOOST_LAMBDA_COMMA_OPERATOR_NAME, other_action<comma_action>, const A, const B, const_copy_argument)
+BOOST_LAMBDA_BE2(BOOST_LAMBDA_COMMA_OPERATOR_NAME, other_action<comma_action>, const A, const B, const_copy_argument)
+BOOST_LAMBDA_BE3(BOOST_LAMBDA_COMMA_OPERATOR_NAME, other_action<comma_action>, const A, const B, const_copy_argument)
+
+
+
+namespace detail {
+
+// special cases for ostream& << Any and istream& >> Any ---------------
+// the actual stream classes may vary and thus a specialisation for, 
+// say ostream& does not match (the general case above is chosen). 
+// Therefore we specialise for non-const reference:
+// if the left argument is a stream, we store the stream as reference
+// if it is something else, we store a const plain by default
+
+// Note that the overloading is const vs. non-const first argument
+
+#ifdef BOOST_NO_TEMPLATED_STREAMS
+template<class T> struct convert_ostream_to_ref_others_to_c_plain_by_default {
+  typedef typename detail::IF<
+                       ndnboost::is_convertible<T*, std::ostream*>::value,
+                       T&,
+                       typename const_copy_argument <T>::type
+                     >::RET type;
+};
+
+template<class T> struct convert_istream_to_ref_others_to_c_plain_by_default {
+  typedef typename detail::IF<
+                       ndnboost::is_convertible<T*, std::istream*>::value,
+                       T&,
+                       typename const_copy_argument <T>::type
+                     >::RET type;
+};
+#else
+
+template<class T> struct convert_ostream_to_ref_others_to_c_plain_by_default {
+  typedef typename detail::IF<
+                       is_instance_of_2<
+                         T, std::basic_ostream
+                       >::value,
+                       T&,
+                       typename const_copy_argument <T>::type
+                     >::RET type;
+};
+
+template<class T> struct convert_istream_to_ref_others_to_c_plain_by_default {
+  typedef typename detail::IF<
+                       is_instance_of_2<
+                         T, std::basic_istream
+                       >::value,
+                       T&,
+                       typename const_copy_argument <T>::type
+                     >::RET type;
+};
+#endif
+
+} // detail
+
+BOOST_LAMBDA_BE2(operator<<, bitwise_action< leftshift_action>, A, const B, detail::convert_ostream_to_ref_others_to_c_plain_by_default)
+BOOST_LAMBDA_BE2(operator>>, bitwise_action< rightshift_action>, A, const B, detail::convert_istream_to_ref_others_to_c_plain_by_default)      
+
+
+// special case for io_manipulators.
+// function references cannot be given as arguments to lambda operator
+// expressions in general. With << and >> the use of manipulators is
+// so common, that specializations are provided to make them work.
+
+template<class Arg, class Ret, class ManipArg>
+inline const 
+lambda_functor<
+  lambda_functor_base<
+    bitwise_action<leftshift_action>,
+    tuple<lambda_functor<Arg>, Ret(&)(ManipArg)> 
+  > 
+>
+operator<<(const lambda_functor<Arg>& a, Ret(&b)(ManipArg))
+{
+  return 
+      lambda_functor_base<
+        bitwise_action<leftshift_action>,
+        tuple<lambda_functor<Arg>, Ret(&)(ManipArg)>
+      > 
+    ( tuple<lambda_functor<Arg>, Ret(&)(ManipArg)>(a, b) );
+}
+
+template<class Arg, class Ret, class ManipArg>
+inline const 
+lambda_functor<
+  lambda_functor_base<
+    bitwise_action<rightshift_action>,
+    tuple<lambda_functor<Arg>, Ret(&)(ManipArg)>
+  > 
+>
+operator>>(const lambda_functor<Arg>& a, Ret(&b)(ManipArg))
+{
+  return 
+      lambda_functor_base<
+        bitwise_action<rightshift_action>,
+        tuple<lambda_functor<Arg>, Ret(&)(ManipArg)>
+      > 
+    ( tuple<lambda_functor<Arg>, Ret(&)(ManipArg)>(a, b) );
+}
+
+
+// (+ and -) take their arguments as const references. 
+// This has consquences with pointer artihmetic
+// E.g int a[]; ... *a = 1 works but not *(a+1) = 1. 
+// the result of a+1 would be const
+// To make the latter work too, 
+// non-const arrays are taken as non-const and stored as non-const as well.
+#if defined  BOOST_LAMBDA_PTR_ARITHMETIC_E1
+#error "Multiple defines of  BOOST_LAMBDA_PTR_ARITHMETIC_E1"
+#endif
+
+#define BOOST_LAMBDA_PTR_ARITHMETIC_E1(OPER_NAME, ACTION, CONSTB)           \
+template<class Arg, int N, class B>                                         \
+inline const                                                                \
+lambda_functor<                                                             \
+  lambda_functor_base<ACTION, tuple<lambda_functor<Arg>, CONSTB(&)[N]> >    \
+>                                                                           \
+OPER_NAME (const lambda_functor<Arg>& a, CONSTB(&b)[N])                     \
+{                                                                           \
+  return                                                                    \
+    lambda_functor_base<ACTION, tuple<lambda_functor<Arg>, CONSTB(&)[N]> >  \
+  (tuple<lambda_functor<Arg>, CONSTB(&)[N]>(a, b));                         \
+}
+
+
+#if defined  BOOST_LAMBDA_PTR_ARITHMETIC_E2
+#error "Multiple defines of  BOOST_LAMBDA_PTR_ARITHMETIC_E2"
+#endif
+
+#define BOOST_LAMBDA_PTR_ARITHMETIC_E2(OPER_NAME, ACTION, CONSTA)           \
+template<int N, class A, class Arg>                                         \
+inline const                                                                \
+lambda_functor<                                                             \
+  lambda_functor_base<ACTION, tuple<CONSTA(&)[N], lambda_functor<Arg> > >   \
+>                                                                           \
+OPER_NAME (CONSTA(&a)[N], const lambda_functor<Arg>& b)                     \
+{                                                                           \
+  return                                                                    \
+    lambda_functor_base<ACTION, tuple<CONSTA(&)[N], lambda_functor<Arg> > > \
+    (tuple<CONSTA(&)[N], lambda_functor<Arg> >(a, b));                      \
+}
+
+
+BOOST_LAMBDA_PTR_ARITHMETIC_E1(operator+, arithmetic_action<plus_action>, B)
+BOOST_LAMBDA_PTR_ARITHMETIC_E2(operator+, arithmetic_action<plus_action>, A)
+BOOST_LAMBDA_PTR_ARITHMETIC_E1(operator+, arithmetic_action<plus_action>,const B)
+BOOST_LAMBDA_PTR_ARITHMETIC_E2(operator+, arithmetic_action<plus_action>,const A)
+
+
+//BOOST_LAMBDA_PTR_ARITHMETIC_E1(operator-, arithmetic_action<minus_action>)
+// This is not needed, since the result of ptr-ptr is an rvalue anyway
+
+BOOST_LAMBDA_PTR_ARITHMETIC_E2(operator-, arithmetic_action<minus_action>, A)
+BOOST_LAMBDA_PTR_ARITHMETIC_E2(operator-, arithmetic_action<minus_action>, const A)
+
+
+#undef BOOST_LAMBDA_BE1
+#undef BOOST_LAMBDA_BE2
+#undef BOOST_LAMBDA_BE3
+#undef BOOST_LAMBDA_BE
+#undef BOOST_LAMBDA_COMMA_OPERATOR_NAME
+
+#undef BOOST_LAMBDA_PTR_ARITHMETIC_E1
+#undef BOOST_LAMBDA_PTR_ARITHMETIC_E2
+
+
+// ---------------------------------------------------------------------
+// unary operators -----------------------------------------------------
+// ---------------------------------------------------------------------
+
+#if defined BOOST_LAMBDA_UE
+#error "Multiple defines of BOOST_LAMBDA_UE"
+#endif
+
+#define BOOST_LAMBDA_UE(OPER_NAME, ACTION)                                 \
+template<class Arg>                                                        \
+inline const                                                               \
+lambda_functor<lambda_functor_base<ACTION, tuple<lambda_functor<Arg> > > > \
+OPER_NAME (const lambda_functor<Arg>& a)                                   \
+{                                                                          \
+  return                                                                   \
+    lambda_functor_base<ACTION, tuple<lambda_functor<Arg> > >              \
+    ( tuple<lambda_functor<Arg> >(a) );                                    \
+}
+
+
+BOOST_LAMBDA_UE(operator+, unary_arithmetic_action<plus_action>)
+BOOST_LAMBDA_UE(operator-, unary_arithmetic_action<minus_action>)
+BOOST_LAMBDA_UE(operator~, bitwise_action<not_action>)
+BOOST_LAMBDA_UE(operator!, logical_action<not_action>)
+BOOST_LAMBDA_UE(operator++, pre_increment_decrement_action<increment_action>)
+BOOST_LAMBDA_UE(operator--, pre_increment_decrement_action<decrement_action>)
+BOOST_LAMBDA_UE(operator*, other_action<contentsof_action>)
+BOOST_LAMBDA_UE(operator&, other_action<addressof_action>)
+
+#if defined BOOST_LAMBDA_POSTFIX_UE
+#error "Multiple defines of BOOST_LAMBDA_POSTFIX_UE"
+#endif
+
+#define BOOST_LAMBDA_POSTFIX_UE(OPER_NAME, ACTION)                         \
+template<class Arg>                                                        \
+inline const                                                               \
+lambda_functor<lambda_functor_base<ACTION, tuple<lambda_functor<Arg> > > > \
+OPER_NAME (const lambda_functor<Arg>& a, int)                              \
+{                                                                          \
+  return                                                                   \
+    lambda_functor_base<ACTION, tuple<lambda_functor<Arg> > >              \
+    ( tuple<lambda_functor<Arg> >(a) );                                    \
+}
+
+
+BOOST_LAMBDA_POSTFIX_UE(operator++, post_increment_decrement_action<increment_action>)
+BOOST_LAMBDA_POSTFIX_UE(operator--, post_increment_decrement_action<decrement_action>)
+
+#undef BOOST_LAMBDA_UE
+#undef BOOST_LAMBDA_POSTFIX_UE
+
+} // namespace lambda
+} // namespace ndnboost
+
+#endif
diff --git a/ndnboost/lambda/detail/ret.hpp b/ndnboost/lambda/detail/ret.hpp
new file mode 100644
index 0000000..8261bbd
--- /dev/null
+++ b/ndnboost/lambda/detail/ret.hpp
@@ -0,0 +1,325 @@
+// Boost Lambda Library  ret.hpp -----------------------------------------
+
+// Copyright (C) 1999, 2000 Jaakko Jarvi (jaakko.jarvi@cs.utu.fi)
+//
+// Distributed under the Boost Software License, Version 1.0. (See
+// accompanying file LICENSE_1_0.txt or copy at
+// http://www.boost.org/LICENSE_1_0.txt)
+//
+// For more information, see www.boost.org
+
+
+#ifndef BOOST_LAMBDA_RET_HPP
+#define BOOST_LAMBDA_RET_HPP
+
+namespace ndnboost { 
+namespace lambda {
+
+  // TODO:
+
+//  Add specializations for function references for ret, protect and unlambda
+//  e.g void foo(); unlambda(foo); fails, as it would add a const qualifier
+  // for a function type. 
+  // on the other hand unlambda(*foo) does work
+
+
+// -- ret -------------------------
+// the explicit return type template 
+
+  // TODO: It'd be nice to make ret a nop for other than lambda functors
+  // but causes an ambiguiyty with gcc (not with KCC), check what is the
+  // right interpretation.
+
+  //  // ret for others than lambda functors has no effect
+  // template <class U, class T>
+  // inline const T& ret(const T& t) { return t; }
+
+
+template<class RET, class Arg>
+inline const 
+lambda_functor<
+  lambda_functor_base<
+    explicit_return_type_action<RET>, 
+    tuple<lambda_functor<Arg> >
+  > 
+>
+ret(const lambda_functor<Arg>& a1)
+{
+  return  
+    lambda_functor_base<
+      explicit_return_type_action<RET>, 
+      tuple<lambda_functor<Arg> >
+    > 
+    (tuple<lambda_functor<Arg> >(a1));
+}
+
+// protect ------------------
+
+  // protecting others than lambda functors has no effect
+template <class T>
+inline const T& protect(const T& t) { return t; }
+
+template<class Arg>
+inline const 
+lambda_functor<
+  lambda_functor_base<
+    protect_action, 
+    tuple<lambda_functor<Arg> >
+  > 
+>
+protect(const lambda_functor<Arg>& a1)
+{
+  return 
+      lambda_functor_base<
+        protect_action, 
+        tuple<lambda_functor<Arg> >
+      > 
+    (tuple<lambda_functor<Arg> >(a1));
+}
+   
+// -------------------------------------------------------------------
+
+// Hides the lambda functorness of a lambda functor. 
+// After this, the functor is immune to argument substitution, etc.
+// This can be used, e.g. to make it safe to pass lambda functors as 
+// arguments to functions, which might use them as target functions
+
+// note, unlambda and protect are different things. Protect hides the lambda
+// functor for one application, unlambda for good.
+
+template <class LambdaFunctor>
+class non_lambda_functor
+{
+  LambdaFunctor lf;
+public:
+  
+  // This functor defines the result_type typedef.
+  // The result type must be deducible without knowing the arguments
+
+  template <class SigArgs> struct sig {
+    typedef typename 
+      LambdaFunctor::inherited:: 
+        template sig<typename SigArgs::tail_type>::type type;
+  };
+
+  explicit non_lambda_functor(const LambdaFunctor& a) : lf(a) {}
+
+  typename LambdaFunctor::nullary_return_type  
+  operator()() const {
+    return lf.template 
+      call<typename LambdaFunctor::nullary_return_type>
+        (cnull_type(), cnull_type(), cnull_type(), cnull_type()); 
+  }
+
+  template<class A>
+  typename sig<tuple<const non_lambda_functor, A&> >::type 
+  operator()(A& a) const {
+    return lf.template call<typename sig<tuple<const non_lambda_functor, A&> >::type >(a, cnull_type(), cnull_type(), cnull_type()); 
+  }
+
+  template<class A, class B>
+  typename sig<tuple<const non_lambda_functor, A&, B&> >::type 
+  operator()(A& a, B& b) const {
+    return lf.template call<typename sig<tuple<const non_lambda_functor, A&, B&> >::type >(a, b, cnull_type(), cnull_type()); 
+  }
+
+  template<class A, class B, class C>
+  typename sig<tuple<const non_lambda_functor, A&, B&, C&> >::type 
+  operator()(A& a, B& b, C& c) const {
+    return lf.template call<typename sig<tuple<const non_lambda_functor, A&, B&, C&> >::type>(a, b, c, cnull_type()); 
+  }
+};
+
+template <class Arg>
+inline const Arg& unlambda(const Arg& a) { return a; }
+
+template <class Arg>
+inline const non_lambda_functor<lambda_functor<Arg> > 
+unlambda(const lambda_functor<Arg>& a)
+{
+  return non_lambda_functor<lambda_functor<Arg> >(a);
+}
+
+  // Due to a language restriction, lambda functors cannot be made to
+  // accept non-const rvalue arguments. Usually iterators do not return 
+  // temporaries, but sometimes they do. That's why a workaround is provided.
+  // Note, that this potentially breaks const correctness, so be careful!
+
+// any lambda functor can be turned into a const_incorrect_lambda_functor
+// The operator() takes arguments as consts and then casts constness
+// away. So this breaks const correctness!!! but is a necessary workaround
+// in some cases due to language limitations.
+// Note, that this is not a lambda_functor anymore, so it can not be used
+// as a sub lambda expression.
+
+template <class LambdaFunctor>
+struct const_incorrect_lambda_functor {
+  LambdaFunctor lf;
+public:
+
+  explicit const_incorrect_lambda_functor(const LambdaFunctor& a) : lf(a) {}
+
+  template <class SigArgs> struct sig {
+    typedef typename
+      LambdaFunctor::inherited::template 
+        sig<typename SigArgs::tail_type>::type type;
+  };
+
+  // The nullary case is not needed (no arguments, no parameter type problems)
+
+  template<class A>
+  typename sig<tuple<const const_incorrect_lambda_functor, A&> >::type
+  operator()(const A& a) const {
+    return lf.template call<typename sig<tuple<const const_incorrect_lambda_functor, A&> >::type >(const_cast<A&>(a), cnull_type(), cnull_type(), cnull_type());
+  }
+
+  template<class A, class B>
+  typename sig<tuple<const const_incorrect_lambda_functor, A&, B&> >::type
+  operator()(const A& a, const B& b) const {
+    return lf.template call<typename sig<tuple<const const_incorrect_lambda_functor, A&, B&> >::type >(const_cast<A&>(a), const_cast<B&>(b), cnull_type(), cnull_type());
+  }
+
+  template<class A, class B, class C>
+  typename sig<tuple<const const_incorrect_lambda_functor, A&, B&, C&> >::type
+  operator()(const A& a, const B& b, const C& c) const {
+    return lf.template call<typename sig<tuple<const const_incorrect_lambda_functor, A&, B&, C&> >::type>(const_cast<A&>(a), const_cast<B&>(b), const_cast<C&>(c), cnull_type());
+  }
+};
+
+// ------------------------------------------------------------------------
+// any lambda functor can be turned into a const_parameter_lambda_functor
+// The operator() takes arguments as const.
+// This is useful if lambda functors are called with non-const rvalues.
+// Note, that this is not a lambda_functor anymore, so it can not be used
+// as a sub lambda expression.
+
+template <class LambdaFunctor>
+struct const_parameter_lambda_functor {
+  LambdaFunctor lf;
+public:
+
+  explicit const_parameter_lambda_functor(const LambdaFunctor& a) : lf(a) {}
+
+  template <class SigArgs> struct sig {
+    typedef typename
+      LambdaFunctor::inherited::template 
+        sig<typename SigArgs::tail_type>::type type;
+  };
+
+  // The nullary case is not needed: no arguments, no constness problems.
+
+  template<class A>
+  typename sig<tuple<const const_parameter_lambda_functor, const A&> >::type
+  operator()(const A& a) const {
+    return lf.template call<typename sig<tuple<const const_parameter_lambda_functor, const A&> >::type >(a, cnull_type(), cnull_type(), cnull_type());
+  }
+
+  template<class A, class B>
+  typename sig<tuple<const const_parameter_lambda_functor, const A&, const B&> >::type
+  operator()(const A& a, const B& b) const {
+    return lf.template call<typename sig<tuple<const const_parameter_lambda_functor, const A&, const B&> >::type >(a, b, cnull_type(), cnull_type());
+  }
+
+  template<class A, class B, class C>
+  typename sig<tuple<const const_parameter_lambda_functor, const A&, const B&, const C&>
+>::type
+  operator()(const A& a, const B& b, const C& c) const {
+    return lf.template call<typename sig<tuple<const const_parameter_lambda_functor, const A&, const B&, const C&> >::type>(a, b, c, cnull_type());
+  }
+};
+
+template <class Arg>
+inline const const_incorrect_lambda_functor<lambda_functor<Arg> >
+break_const(const lambda_functor<Arg>& lf)
+{
+  return const_incorrect_lambda_functor<lambda_functor<Arg> >(lf);
+}
+
+
+template <class Arg>
+inline const const_parameter_lambda_functor<lambda_functor<Arg> >
+const_parameters(const lambda_functor<Arg>& lf)
+{
+  return const_parameter_lambda_functor<lambda_functor<Arg> >(lf);
+}
+
+// make void ------------------------------------------------
+// make_void( x ) turns a lambda functor x with some return type y into
+// another lambda functor, which has a void return type
+// when called, the original return type is discarded
+
+// we use this action. The action class will be called, which means that
+// the wrapped lambda functor is evaluated, but we just don't do anything
+// with the result.
+struct voidifier_action {
+  template<class Ret, class A> static void apply(A&) {}
+};
+
+template<class Args> struct return_type_N<voidifier_action, Args> {
+  typedef void type;
+};
+
+template<class Arg1>
+inline const 
+lambda_functor<
+  lambda_functor_base<
+    action<1, voidifier_action>,
+    tuple<lambda_functor<Arg1> >
+  > 
+> 
+make_void(const lambda_functor<Arg1>& a1) { 
+return 
+    lambda_functor_base<
+      action<1, voidifier_action>,
+      tuple<lambda_functor<Arg1> >
+    > 
+  (tuple<lambda_functor<Arg1> > (a1));
+}
+
+// for non-lambda functors, make_void does nothing 
+// (the argument gets evaluated immediately)
+
+template<class Arg1>
+inline const 
+lambda_functor<
+  lambda_functor_base<do_nothing_action, null_type> 
+> 
+make_void(const Arg1&) { 
+return 
+    lambda_functor_base<do_nothing_action, null_type>();
+}
+
+// std_functor -----------------------------------------------------
+
+//  The STL uses the result_type typedef as the convention to let binders know
+//  the return type of a function object. 
+//  LL uses the sig template.
+//  To let LL know that the function object has the result_type typedef 
+//  defined, it can be wrapped with the std_functor function.
+
+
+// Just inherit form the template parameter (the standard functor), 
+// and provide a sig template. So we have a class which is still the
+// same functor + the sig template.
+
+template<class T>
+struct result_type_to_sig : public T {
+  template<class Args> struct sig { typedef typename T::result_type type; };
+  result_type_to_sig(const T& t) : T(t) {}
+};
+
+template<class F>
+inline result_type_to_sig<F> std_functor(const F& f) { return f; }
+
+
+} // namespace lambda 
+} // namespace ndnboost
+
+#endif
+
+
+
+
+
+
+
diff --git a/ndnboost/lambda/detail/return_type_traits.hpp b/ndnboost/lambda/detail/return_type_traits.hpp
new file mode 100644
index 0000000..58771b7
--- /dev/null
+++ b/ndnboost/lambda/detail/return_type_traits.hpp
@@ -0,0 +1,282 @@
+//  return_type_traits.hpp -- Boost Lambda Library ---------------------------
+
+// Copyright (C) 1999, 2000 Jaakko Jarvi (jaakko.jarvi@cs.utu.fi)
+//
+// Distributed under the Boost Software License, Version 1.0. (See
+// accompanying file LICENSE_1_0.txt or copy at
+// http://www.boost.org/LICENSE_1_0.txt)
+//
+// For more information, see www.boost.org
+
+
+#ifndef BOOST_LAMBDA_RETURN_TYPE_TRAITS_HPP
+#define BOOST_LAMBDA_RETURN_TYPE_TRAITS_HPP
+
+#include "ndnboost/mpl/has_xxx.hpp"
+
+#include <cstddef> // needed for the ptrdiff_t
+
+namespace ndnboost { 
+namespace lambda {
+
+using ::ndnboost::type_traits::ice_and;
+using ::ndnboost::type_traits::ice_or;
+using ::ndnboost::type_traits::ice_not;
+
+// Much of the type deduction code for standard arithmetic types 
+// from Gary Powell
+
+  // different arities:
+template <class Act, class A1> struct return_type_1; // 1-ary actions
+template <class Act, class A1, class A2> struct return_type_2; // 2-ary
+template <class Act, class Args> struct return_type_N; // >3- ary
+
+template <class Act, class A1> struct return_type_1_prot;
+template <class Act, class A1, class A2> struct return_type_2_prot; // 2-ary
+template <class Act, class A1> struct return_type_N_prot; // >3-ary
+
+
+namespace detail {
+
+template<class> class return_type_deduction_failure {};
+
+  // In some cases return type deduction should fail (an invalid lambda 
+  // expression). Sometimes the lambda expression can be ok, the return type
+  // just is not deducible (user defined operators). Then return type deduction
+  // should never be entered at all, and the use of ret<> does this.
+  // However, for nullary lambda functors, return type deduction is always
+  // entered, and there seems to be no way around this.
+
+  // (the return type is part of the prototype of the non-template
+  // operator()(). The prototype is instantiated, even though the body 
+  // is not.) 
+ 
+  // So, in the case the return type deduction should fail, it should not
+  // fail directly, but rather result in a valid but wrong return type,
+  // causing a compile time error only if the function is really called.
+
+
+
+} // end detail
+
+
+
+// return_type_X_prot classes --------------------------------------------
+// These classes are the first layer that gets instantiated from the 
+// lambda_functor_base sig templates. It will check whether 
+// the action is protectable and one of arguments is "protected" or its
+// evaluation will otherwise result in another lambda functor.
+// If this is a case, the result type will be another lambda functor.
+
+// The arguments are always non-reference types, except for comma action
+// where the right argument can be a reference too. This is because it 
+// matters (in the builtin case) whether the argument is an lvalue or 
+// rvalue: int i; i, 1 -> rvalue; 1, i -> lvalue
+
+template <class Act, class A> struct return_type_1_prot {
+public:
+  typedef typename 
+    detail::IF<
+  //      is_protectable<Act>::value && is_lambda_functor<A>::value,
+      ice_and<is_protectable<Act>::value, is_lambda_functor<A>::value>::value,
+      lambda_functor<
+        lambda_functor_base< 
+          Act, 
+          tuple<typename detail::remove_reference_and_cv<A>::type>
+        >
+      >,
+      typename return_type_1<Act, A>::type
+    >::RET type;  
+};
+
+  // take care of the unavoidable instantiation for nullary case
+template<class Act> struct return_type_1_prot<Act, null_type> {
+  typedef null_type type;
+};
+ 
+// Unary actions (result from unary operators)
+// do not have a default return type.
+template<class Act, class A> struct return_type_1 { 
+   typedef typename 
+     detail::return_type_deduction_failure<return_type_1> type;
+};
+
+
+namespace detail {
+
+  template <class T>
+  class protect_conversion {
+      typedef typename ndnboost::remove_reference<T>::type non_ref_T;
+    public:
+
+  // add const to rvalues, so that all rvalues are stored as const in 
+  // the args tuple
+    typedef typename detail::IF_type<
+//      ndnboost::is_reference<T>::value && !ndnboost::is_const<non_ref_T>::value,
+      ice_and<ndnboost::is_reference<T>::value,
+              ice_not<ndnboost::is_const<non_ref_T>::value>::value>::value,
+      detail::identity_mapping<T>,
+      const_copy_argument<non_ref_T> // handles funtion and array 
+    >::type type;                      // types correctly
+  };
+
+} // end detail
+
+template <class Act, class A, class B> struct return_type_2_prot {
+
+// experimental feature
+  // We may have a lambda functor as a result type of a subexpression 
+  // (if protect) has  been used.
+  // Thus, if one of the parameter types is a lambda functor, the result
+  // is a lambda functor as well. 
+  // We need to make a conservative choise here.
+  // The resulting lambda functor stores all const reference arguments as
+  // const copies. References to non-const are stored as such.
+  // So if the source of the argument is a const open argument, a bound
+  // argument stored as a const reference, or a function returning a 
+  // const reference, that information is lost. There is no way of 
+  // telling apart 'real const references' from just 'LL internal
+  // const references' (or it would be really hard)
+
+  // The return type is a subclass of lambda_functor, which has a converting 
+  // copy constructor. It can copy any lambda functor, that has the same 
+  // action type and code, and a copy compatible argument tuple.
+
+
+  typedef typename ndnboost::remove_reference<A>::type non_ref_A;
+  typedef typename ndnboost::remove_reference<B>::type non_ref_B;
+
+typedef typename 
+  detail::IF<
+//    is_protectable<Act>::value &&
+//      (is_lambda_functor<A>::value || is_lambda_functor<B>::value),
+    ice_and<is_protectable<Act>::value,
+            ice_or<is_lambda_functor<A>::value, 
+                   is_lambda_functor<B>::value>::value>::value,
+    lambda_functor<
+      lambda_functor_base< 
+        Act, 
+        tuple<typename detail::protect_conversion<A>::type, 
+              typename detail::protect_conversion<B>::type>
+      >
+    >,
+    typename return_type_2<Act, non_ref_A, non_ref_B>::type
+  >::RET type;
+};
+
+  // take care of the unavoidable instantiation for nullary case
+template<class Act> struct return_type_2_prot<Act, null_type, null_type> {
+  typedef null_type type;
+};
+  // take care of the unavoidable instantiation for nullary case
+template<class Act, class Other> struct return_type_2_prot<Act, Other, null_type> {
+  typedef null_type type;
+};
+  // take care of the unavoidable instantiation for nullary case
+template<class Act, class Other> struct return_type_2_prot<Act, null_type, Other> {
+  typedef null_type type;
+};
+
+  // comma is a special case, as the user defined operator can return
+  // an lvalue (reference) too, hence it must be handled at this level.
+template<class A, class B> 
+struct return_type_2_comma
+{
+  typedef typename ndnboost::remove_reference<A>::type non_ref_A;
+  typedef typename ndnboost::remove_reference<B>::type non_ref_B;
+
+typedef typename 
+  detail::IF<
+//  is_protectable<other_action<comma_action> >::value && // it is protectable
+//  (is_lambda_functor<A>::value || is_lambda_functor<B>::value),
+    ice_and<is_protectable<other_action<comma_action> >::value, // it is protectable
+            ice_or<is_lambda_functor<A>::value, 
+                   is_lambda_functor<B>::value>::value>::value,
+    lambda_functor<
+      lambda_functor_base< 
+        other_action<comma_action>, 
+        tuple<typename detail::protect_conversion<A>::type, 
+              typename detail::protect_conversion<B>::type>
+      >
+    >,
+    typename 
+      return_type_2<other_action<comma_action>, non_ref_A, non_ref_B>::type
+  >::RET type1;
+
+   // if no user defined return_type_2 (or plain_return_type_2) specialization
+  // matches, then return the righthand argument
+  typedef typename 
+    detail::IF<
+      ndnboost::is_same<type1, detail::unspecified>::value, 
+      B,
+      type1
+    >::RET type;
+
+};
+
+
+  // currently there are no protectable actions with > 2 args
+
+template<class Act, class Args> struct return_type_N_prot {
+  typedef typename return_type_N<Act, Args>::type type;
+};
+
+  // take care of the unavoidable instantiation for nullary case
+template<class Act> struct return_type_N_prot<Act, null_type> {
+  typedef null_type type;
+};
+
+// handle different kind of actions ------------------------
+
+  // use the return type given in the bind invocation as bind<Ret>(...)
+template<int I, class Args, class Ret> 
+struct return_type_N<function_action<I, Ret>, Args> { 
+  typedef Ret type;
+};
+
+// ::result_type support
+
+namespace detail
+{
+
+BOOST_MPL_HAS_XXX_TRAIT_DEF(result_type)
+
+template<class F> struct get_result_type
+{
+  typedef typename F::result_type type;
+};
+
+template<class F, class A> struct get_sig
+{
+  typedef typename function_adaptor<F>::template sig<A>::type type;
+};
+
+} // namespace detail
+
+  // Ret is detail::unspecified, so try to deduce return type
+template<int I, class Args> 
+struct return_type_N<function_action<I, detail::unspecified>, Args > { 
+
+  // in the case of function action, the first element in Args is 
+  // some type of function
+  typedef typename Args::head_type Func;
+  typedef typename detail::remove_reference_and_cv<Func>::type plain_Func;
+
+public: 
+  // pass the function to function_adaptor, and get the return type from 
+  // that
+  typedef typename detail::IF<
+    detail::has_result_type<plain_Func>::value,
+    detail::get_result_type<plain_Func>,
+    detail::get_sig<plain_Func, Args>
+  >::RET::type type;
+};
+
+
+} // namespace lambda
+} // namespace ndnboost
+
+#endif
+
+
+
diff --git a/ndnboost/lambda/detail/select_functions.hpp b/ndnboost/lambda/detail/select_functions.hpp
new file mode 100644
index 0000000..7b3ef8a
--- /dev/null
+++ b/ndnboost/lambda/detail/select_functions.hpp
@@ -0,0 +1,74 @@
+// -- select_functions.hpp -- Boost Lambda Library --------------------------
+
+// Copyright (C) 1999, 2000 Jaakko Jarvi (jaakko.jarvi@cs.utu.fi)
+//
+// Distributed under the Boost Software License, Version 1.0. (See
+// accompanying file LICENSE_1_0.txt or copy at
+// http://www.boost.org/LICENSE_1_0.txt)
+//
+// For more information, see http://www.boost.org
+
+
+#ifndef BOOST_LAMBDA_SELECT_FUNCTIONS_HPP
+#define BOOST_LAMBDA_SELECT_FUNCTIONS_HPP
+
+namespace ndnboost { 
+namespace lambda {
+namespace detail {
+
+
+// select functions -------------------------------
+template<class Any, CALL_TEMPLATE_ARGS>
+inline Any& select(Any& any, CALL_FORMAL_ARGS) { CALL_USE_ARGS; return any; }
+
+
+template<class Arg, CALL_TEMPLATE_ARGS>
+inline typename Arg::template sig<tuple<CALL_REFERENCE_TYPES> >::type
+select ( const lambda_functor<Arg>& op, CALL_FORMAL_ARGS ) { 
+  return op.template call<
+    typename Arg::template sig<tuple<CALL_REFERENCE_TYPES> >::type
+  >(CALL_ACTUAL_ARGS); 
+}
+template<class Arg, CALL_TEMPLATE_ARGS>
+inline typename Arg::template sig<tuple<CALL_REFERENCE_TYPES> >::type
+select ( lambda_functor<Arg>& op, CALL_FORMAL_ARGS) { 
+  return op.template call<
+    typename Arg::template sig<tuple<CALL_REFERENCE_TYPES> >::type
+  >(CALL_ACTUAL_ARGS); 
+}
+
+// ------------------------------------------------------------------------
+// select functions where the return type is explicitly given
+// Note: on many functions, this return type is just discarded.
+// The select functions are inside a class template, and the return type
+// is a class template argument.
+// The first implementation used function templates with an explicitly 
+// specified template parameter.
+// However, this resulted in ambiguous calls (at least with gcc 2.95.2 
+// and edg 2.44). Not sure whether the compilers were right or wrong. 
+  
+template<class RET> struct r_select {
+
+// Any == RET
+  template<class Any, CALL_TEMPLATE_ARGS>
+  static 
+  inline RET go (Any& any, CALL_FORMAL_ARGS) { CALL_USE_ARGS; return any; }
+
+
+  template<class Arg, CALL_TEMPLATE_ARGS> 
+  static 
+  inline RET go (const lambda_functor<Arg>& op, CALL_FORMAL_ARGS ) {
+    return op.template call<RET>(CALL_ACTUAL_ARGS); 
+  }
+  template<class Arg, CALL_TEMPLATE_ARGS> 
+  static 
+  inline RET go (lambda_functor<Arg>& op, CALL_FORMAL_ARGS ) { 
+    return op.template call<RET>(CALL_ACTUAL_ARGS); 
+  }
+};
+   
+} // namespace detail
+} // namespace lambda
+} // namespace ndnboost
+
+#endif
