Skip to content

Commit 51e86a3

Browse files
thorsten-kleinkris-jusiak
authored andcommitted
support googletest 1.12.1
1 parent e1c760f commit 51e86a3

1 file changed

Lines changed: 5 additions & 5 deletions

File tree

include/GUnit/GMock.h

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -192,7 +192,7 @@ UnregisterCallReactionType UnregisterCallReaction();
192192
template struct GetAccessUnregisterCallReactionType<
193193
&Mock::GetReactionOnUninterestingCalls>;
194194

195-
using AllowUninterestingCallsType = void (*)(const void *);
195+
using AllowUninterestingCallsType = void (*)(uintptr_t);
196196
template <AllowUninterestingCallsType Ptr>
197197
struct GetAccessAllowUninterestingCallsType {
198198
friend AllowUninterestingCallsType AllowUninterestingCalls() { return Ptr; }
@@ -201,7 +201,7 @@ AllowUninterestingCallsType AllowUninterestingCalls();
201201
template struct GetAccessAllowUninterestingCallsType<
202202
&Mock::AllowUninterestingCalls>;
203203

204-
using FailUninterestingCallsType = void (*)(const void *);
204+
using FailUninterestingCallsType = void (*)(uintptr_t);
205205
template <FailUninterestingCallsType Ptr>
206206
struct GetAccessFailUninterestingCallsType {
207207
friend FailUninterestingCallsType FailUninterestingCalls() { return Ptr; }
@@ -367,7 +367,7 @@ class NiceMock<GMock<T>> final : public GMock<T> {
367367
NiceMock(const NiceMock &) = delete;
368368
NiceMock() {
369369
detail::AllowUninterestingCalls()(
370-
internal::ImplicitCast_<GMock<T> *>(this));
370+
reinterpret_cast<uintptr_t>(this));
371371
}
372372
~NiceMock() {
373373
detail::UnregisterCallReaction()(internal::ImplicitCast_<GMock<T> *>(this));
@@ -379,12 +379,12 @@ class StrictMock<GMock<T>> final : public GMock<T> {
379379
public:
380380
template <class... Ts>
381381
StrictMock(Ts &&... ts) : GMock<T>{std::forward<Ts>(ts)...} {
382-
detail::FailUninterestingCalls()(internal::ImplicitCast_<GMock<T> *>(this));
382+
detail::FailUninterestingCalls()(reinterpret_cast<uintptr_t>(this));
383383
}
384384
StrictMock(StrictMock &&) = default;
385385
StrictMock(const StrictMock &) = delete;
386386
StrictMock() {
387-
detail::FailUninterestingCalls()(internal::ImplicitCast_<GMock<T> *>(this));
387+
detail::FailUninterestingCalls()(reinterpret_cast<uintptr_t>(this));
388388
}
389389
~StrictMock() {
390390
detail::UnregisterCallReaction()(internal::ImplicitCast_<GMock<T> *>(this));

0 commit comments

Comments
 (0)