From 840c711e7bd7240b3f451821473c759ad3578412 Mon Sep 17 00:00:00 2001 From: Arkady Shapkin Date: Thu, 8 Jun 2017 02:28:17 +0300 Subject: Fix gmock tests when std::unary_function unavailable --- googlemock/test/gmock-matchers_test.cc | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'googlemock') diff --git a/googlemock/test/gmock-matchers_test.cc b/googlemock/test/gmock-matchers_test.cc index 207c6fdd..4beaec4c 100644 --- a/googlemock/test/gmock-matchers_test.cc +++ b/googlemock/test/gmock-matchers_test.cc @@ -3936,8 +3936,11 @@ TEST(ResultOfTest, WorksForFunctionReferences) { // Tests that ResultOf(f, ...) compiles and works as expected when f is a // function object. -struct Functor : public ::std::unary_function { - result_type operator()(argument_type input) const { +struct Functor { + typedef std::string result_type; + typedef int argument_type; + + std::string operator()(int input) const { return IntToStringFunction(input); } }; -- cgit v1.2.3