diff options
author | Gennadiy Civil <misterg@google.com> | 2018-04-25 13:10:41 -0400 |
---|---|---|
committer | Gennadiy Civil <misterg@google.com> | 2018-04-25 13:10:41 -0400 |
commit | b539167cf0254f521b791e908f6d3a5ff3f30245 (patch) | |
tree | a0609a9dda7ebefb285bae6e6b0f5e1c577c1051 /googlemock/include/gmock/internal/gmock-internal-utils.h | |
parent | 1114a0202a3147c1ce548c9a2883ce29e80df9e3 (diff) | |
download | googletest-b539167cf0254f521b791e908f6d3a5ff3f30245.tar.gz googletest-b539167cf0254f521b791e908f6d3a5ff3f30245.tar.bz2 googletest-b539167cf0254f521b791e908f6d3a5ff3f30245.zip |
merging,
Diffstat (limited to 'googlemock/include/gmock/internal/gmock-internal-utils.h')
-rw-r--r-- | googlemock/include/gmock/internal/gmock-internal-utils.h | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/googlemock/include/gmock/internal/gmock-internal-utils.h b/googlemock/include/gmock/internal/gmock-internal-utils.h index 20c95c6a..4751788a 100644 --- a/googlemock/include/gmock/internal/gmock-internal-utils.h +++ b/googlemock/include/gmock/internal/gmock-internal-utils.h @@ -344,6 +344,21 @@ GTEST_API_ bool LogIsVisible(LogSeverity severity); GTEST_API_ void Log(LogSeverity severity, const std::string& message, int stack_frames_to_skip); +// A marker class that is used to resolve parameterless expectations to the +// correct overload. This must not be instantiable, to prevent client code from +// accidentally resolving to the overload; for example: +// +// ON_CALL(mock, Method({}, nullptr))… +// +class WithoutMatchers { + private: + WithoutMatchers() {} + friend GTEST_API_ WithoutMatchers GetWithoutMatchers(); +}; + +// Internal use only: access the singleton instance of WithoutMatchers. +GTEST_API_ WithoutMatchers GetWithoutMatchers(); + // TODO(wan@google.com): group all type utilities together. // Type traits. |