diff options
author | Jonathan Wakely <jwakely@redhat.com> | 2019-05-14 21:01:28 +0100 |
---|---|---|
committer | Jonathan Wakely <redi@gcc.gnu.org> | 2019-05-14 21:01:28 +0100 |
commit | ff8b2a0acbc04ce894905a35c1f9e82a1fd2b8ce (patch) | |
tree | 3fb16c7752ab7640bbad46af7c2cf95c1f690e7f | |
parent | b4d12b5eb63f2f7259ac717cf367451ffe54873a (diff) | |
download | gcc-ff8b2a0acbc04ce894905a35c1f9e82a1fd2b8ce.zip gcc-ff8b2a0acbc04ce894905a35c1f9e82a1fd2b8ce.tar.gz gcc-ff8b2a0acbc04ce894905a35c1f9e82a1fd2b8ce.tar.bz2 |
Fix NullablePointer test utility
* testsuite/util/testsuite_allocator.h (NullablePointer::operator bool):
Fix return value.
From-SVN: r271189
-rw-r--r-- | libstdc++-v3/ChangeLog | 5 | ||||
-rw-r--r-- | libstdc++-v3/testsuite/util/testsuite_allocator.h | 2 |
2 files changed, 6 insertions, 1 deletions
diff --git a/libstdc++-v3/ChangeLog b/libstdc++-v3/ChangeLog index 52cd3ad..ecdba1d 100644 --- a/libstdc++-v3/ChangeLog +++ b/libstdc++-v3/ChangeLog @@ -1,3 +1,8 @@ +2019-05-14 Jonathan Wakely <jwakely@redhat.com> + + * testsuite/util/testsuite_allocator.h (NullablePointer::operator bool): + Fix return value. + 2019-05-14 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE> * config/os/solaris/solaris2.10: Move to ... diff --git a/libstdc++-v3/testsuite/util/testsuite_allocator.h b/libstdc++-v3/testsuite/util/testsuite_allocator.h index ac7dc8e..d817ac4 100644 --- a/libstdc++-v3/testsuite/util/testsuite_allocator.h +++ b/libstdc++-v3/testsuite/util/testsuite_allocator.h @@ -600,7 +600,7 @@ namespace __gnu_test NullablePointer() = default; NullablePointer(std::nullptr_t) noexcept : value() { } - explicit operator bool() const noexcept { return value == nullptr; } + explicit operator bool() const noexcept { return value != nullptr; } friend inline bool operator==(NullablePointer lhs, NullablePointer rhs) noexcept |