diff --git a/include/boost/algorithm/cxx14/equal.hpp b/include/boost/algorithm/cxx14/equal.hpp index 4d7b063..857435b 100644 --- a/include/boost/algorithm/cxx14/equal.hpp +++ b/include/boost/algorithm/cxx14/equal.hpp @@ -27,7 +27,7 @@ namespace boost { namespace algorithm { namespace detail { template - struct eq : public std::binary_function { + struct eq { BOOST_CONSTEXPR bool operator () ( const T1& v1, const T2& v2 ) const { return v1 == v2 ;} }; diff --git a/test/all_of_test.cpp b/test/all_of_test.cpp index 4bd3512..a720b0c 100644 --- a/test/all_of_test.cpp +++ b/test/all_of_test.cpp @@ -18,7 +18,7 @@ #include template -struct is_ : public std::unary_function { +struct is_ { BOOST_CXX14_CONSTEXPR is_ ( T v ) : val_ ( v ) {} BOOST_CXX14_CONSTEXPR bool operator () ( T comp ) const { return val_ == comp; } private: diff --git a/test/any_of_test.cpp b/test/any_of_test.cpp index ac089d6..193356c 100644 --- a/test/any_of_test.cpp +++ b/test/any_of_test.cpp @@ -18,7 +18,7 @@ #include template -struct is_ : public std::unary_function { +struct is_ { BOOST_CXX14_CONSTEXPR is_ ( T v ) : val_ ( v ) {} BOOST_CXX14_CONSTEXPR bool operator () ( T comp ) const { return val_ == comp; } private: diff --git a/test/none_of_test.cpp b/test/none_of_test.cpp index d4226e2..9522175 100644 --- a/test/none_of_test.cpp +++ b/test/none_of_test.cpp @@ -18,7 +18,7 @@ #include template -struct is_ : public std::unary_function { +struct is_ { BOOST_CXX14_CONSTEXPR is_ ( T v ) : val_ ( v ) {} BOOST_CXX14_CONSTEXPR bool operator () ( T comp ) const { return val_ == comp; } private: diff --git a/test/one_of_test.cpp b/test/one_of_test.cpp index 807a937..22ccca2 100644 --- a/test/one_of_test.cpp +++ b/test/one_of_test.cpp @@ -18,7 +18,7 @@ #include template -struct is_ : public std::unary_function { +struct is_ { BOOST_CXX14_CONSTEXPR is_ ( T v ) : val_ ( v ) {} BOOST_CXX14_CONSTEXPR bool operator () ( T comp ) const { return val_ == comp; } private: @@ -94,7 +94,7 @@ void test_one () BOOST_CXX14_CONSTEXPR bool constexpr_res = ( !ba::one_of ( some_numbers, is_ ( 6 )) - && ba::one_of ( some_numbers, some_numbers + 3, is_ ( 1 )) + && ba::one_of ( some_numbers + 1, some_numbers + 3, is_ ( 1 )) ); BOOST_CHECK ( constexpr_res );