diff --git a/eo/contrib/MGE/eoVirus.h b/eo/contrib/MGE/eoVirus.h index a7c6aaeea..37b1daf4d 100644 --- a/eo/contrib/MGE/eoVirus.h +++ b/eo/contrib/MGE/eoVirus.h @@ -108,7 +108,12 @@ public: if (is) { virus.resize(bits.size()); std::transform(bits.begin(), bits.end(), virus.begin(), +#if __cplusplus >= 201103L + std::bind(std::equal_to(), std::placeholders::_1, '1')); +#else + // Deprecated since C++11. std::bind2nd(std::equal_to(), '1')); +#endif } } diff --git a/eo/src/eoFunctor.h b/eo/src/eoFunctor.h index 5ccf2e676..7a81252f1 100644 --- a/eo/src/eoFunctor.h +++ b/eo/src/eoFunctor.h @@ -114,7 +114,12 @@ eoFunctorBase::procedure_tag functor_category(const eoF&) result_type **/ template +#if __cplusplus >= 201103L +class eoUF : public eoFunctorBase, public std::function +#else +// Deprecated in C++11 class eoUF : public eoFunctorBase, public std::unary_function +#endif { public : @@ -151,7 +156,12 @@ eoFunctorBase::unary_function_tag functor_category(const eoUF&) result_type **/ template +#if __cplusplus >= 201103L +class eoBF : public eoFunctorBase, public std::function +#else +// Deprecated in C++11 class eoBF : public eoFunctorBase, public std::binary_function +#endif { public : /// virtual dtor here so there is no need to define it in derived classes diff --git a/eo/src/eoSTLFunctor.h b/eo/src/eoSTLFunctor.h index 04f96f9ca..856fd2bfb 100644 --- a/eo/src/eoSTLFunctor.h +++ b/eo/src/eoSTLFunctor.h @@ -79,7 +79,12 @@ void eoSTLF::operator()(void) respectively */ template +#if __cplusplus >= 201103L +class eoSTLUF : public std::function +#else +// Deprecated since C++11 class eoSTLUF : public std::unary_function +#endif { public: eoSTLUF(eoUF& _f) : f(_f) {} @@ -102,7 +107,12 @@ class eoSTLUF : public std::unary_function respectively */ template +#if __cplusplus >= 201103L +class eoSTLBF : public std::function +#else +// Deprecated since C++11 class eoSTLBF : public std::binary_function +#endif { public: eoSTLBF(eoUF& _f) : f(_f) {}