From 38ce18e8e6621433963bd118ed2d36a791efe8e7 Mon Sep 17 00:00:00 2001 From: Krystian Kuzniarek Date: Sat, 24 Aug 2019 12:08:13 +0200 Subject: post-review to db1b7399 (#2396) --- googlemock/include/gmock/gmock-matchers.h | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/googlemock/include/gmock/gmock-matchers.h b/googlemock/include/gmock/gmock-matchers.h index b1c0dc0..fa50903 100644 --- a/googlemock/include/gmock/gmock-matchers.h +++ b/googlemock/include/gmock/gmock-matchers.h @@ -133,14 +133,14 @@ class MatcherCastImpl { // a user-defined conversion from M to T if one exists (assuming M is // a value). return CastImpl(polymorphic_matcher_or_value, - bool_constant>::value>(), - bool_constant::value>()); + std::is_convertible>{}, + std::is_convertible{}); } private: template static Matcher CastImpl(const M& polymorphic_matcher_or_value, - bool_constant /* convertible_to_matcher */, + std::true_type /* convertible_to_matcher */, bool_constant) { // M is implicitly convertible to Matcher, which means that either // M is a polymorphic matcher or Matcher has an implicit constructor @@ -157,8 +157,8 @@ class MatcherCastImpl { // matcher. It's a value of a type implicitly convertible to T. Use direct // initialization to create a matcher. static Matcher CastImpl(const M& value, - bool_constant /* convertible_to_matcher */, - bool_constant /* convertible_to_T */) { + std::false_type /* convertible_to_matcher */, + std::true_type /* convertible_to_T */) { return Matcher(ImplicitCast_(value)); } @@ -173,8 +173,8 @@ class MatcherCastImpl { // // We don't define this method inline as we need the declaration of Eq(). static Matcher CastImpl(const M& value, - bool_constant /* convertible_to_matcher */, - bool_constant /* convertible_to_T */); + std::false_type /* convertible_to_matcher */, + std::false_type /* convertible_to_T */); }; // This more specialized version is used when MatcherCast()'s argument @@ -3600,8 +3600,8 @@ inline Matcher An() { return A(); } template Matcher internal::MatcherCastImpl::CastImpl( - const M& value, internal::bool_constant /* convertible_to_matcher */, - internal::bool_constant /* convertible_to_T */) { + const M& value, std::false_type /* convertible_to_matcher */, + std::false_type /* convertible_to_T */) { return Eq(value); } -- cgit v0.12