You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi,
I cannot run unit tests using gtest in clang with c++11.
The following error has occurred.
In file included from /Users/s-kenji/workspace/my_project/test/jsonparser.cc:5:
In file included from /Users/s-kenji/workspace/my_project/build/googletest-src/googlemock/include/gmock/gmock.h:58:
/Users/ksugimur/workspace/my_project/build/googletest-src/googlemock/include/gmock/gmock-actions.h:388:18: error: use of overloaded operator '==' is ambiguous (with operand types 'const internal::linked_ptr<ActionInterface<void
(const basic_json<std::map, std::vector, basic_string<char>, bool, long long, unsigned long long, double, std::allocator, adl_serializer> &, bool *, int *)> >' and 'nullptr_t')
return impl_ == nullptr && fun_ == nullptr;
~~~~~ ^ ~~~~~~~
The cause of this error is that overloaded operator '==' is not defined for comparison of linked_ptr and nullptr, So I would like to contribute a patch to define the comparison of linked_ptr and nullptr.
Version:
Clang: Apple LLVM version 9.1.0 (clang-902.0.39.1)
OS: macOS HighSierra 10.13.2
commit: 531e294
The text was updated successfully, but these errors were encountered:
s-kenji
changed the title
Build of unit tests fails in clang with c++11.
Build of unit tests fails in clang with c++11
Apr 12, 2018
Hi,
I cannot run unit tests using gtest in clang with c++11.
The following error has occurred.
The cause of this error is that overloaded operator '==' is not defined for comparison of linked_ptr and nullptr, So I would like to contribute a patch to define the comparison of linked_ptr and nullptr.
Version:
Clang: Apple LLVM version 9.1.0 (clang-902.0.39.1)
OS: macOS HighSierra 10.13.2
commit: 531e294
The text was updated successfully, but these errors were encountered: