From 7e6628f374cdb87631b54ccdafd69554eda9536e Mon Sep 17 00:00:00 2001 From: Thorsten Behrens Date: Tue, 15 Apr 2014 21:36:02 +0200 Subject: Unused code: binary_compose, identity Seems noone is using those anymore. Change-Id: I63f775d391c58753e89549dbcae8739708395487 --- include/o3tl/compat_functional.hxx | 35 ----------------------------------- 1 file changed, 35 deletions(-) (limited to 'include/o3tl') diff --git a/include/o3tl/compat_functional.hxx b/include/o3tl/compat_functional.hxx index 0484060bedb8..6dff02bc7b74 100644 --- a/include/o3tl/compat_functional.hxx +++ b/include/o3tl/compat_functional.hxx @@ -37,16 +37,6 @@ namespace o3tl { -/// Identity functor - return the input value -template -struct identity : public std::unary_function -{ - T operator()(const T& y) const - { - return (y); - } -}; - /// Functor, given two parameters, return the first template struct project1st : public std::binary_function @@ -111,31 +101,6 @@ inline unary_compose compose1(const F1& fnction1, const F2& fnction2) return (unary_compose(fnction1, fnction2)); } -/// Calls F2 and F3 for the two args of F1, respectively -template -class binary_compose : public std::unary_function -{ - public: - binary_compose(const F1& fnction1, const F2& fnction2, const F3& fnction3) : ftor1(fnction1), ftor2(fnction2), ftor3(fnction3) {} - - typename F1::result_type operator()(const typename F2::argument_type& y) const - { - return (ftor1(ftor2(y), ftor3(y))); - } - - protected: - F1 ftor1; - F2 ftor2; - F3 ftor3; -}; - -/// Creates functor that calls F2 and F3 for the two args of F1, respectively -template -inline binary_compose compose2(const F1& fnction1, const F2& fnction2, const F3& fnction3) -{ - return (binary_compose(fnction1, fnction2, fnction3)); -} - } // namespace o3tl #endif -- cgit