diff options
author | Zac Hansen <xaxxon@gmail.com> | 2018-03-04 02:53:23 +0300 |
---|---|---|
committer | Neil MacIntosh <neilmac@fb.com> | 2018-03-04 02:53:23 +0300 |
commit | ed3693fd2e6d3dcc20acb6be23cfbf2d1cbb8ecd (patch) | |
tree | 2e102092da682cc14dd2d5129197af2b4927a973 /tests/notnull_tests.cpp | |
parent | 7eb8f41af544941c712916dc0cb2c6c6ef7768ac (diff) |
make explicit not_null move constructor so it is noexcept (#630)
* make explicit not_null move constructor so it is noexcept
* added test for not_null being noexcet move constructible
Diffstat (limited to 'tests/notnull_tests.cpp')
-rw-r--r-- | tests/notnull_tests.cpp | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/tests/notnull_tests.cpp b/tests/notnull_tests.cpp index 4baf7b3..a7ef27e 100644 --- a/tests/notnull_tests.cpp +++ b/tests/notnull_tests.cpp @@ -327,3 +327,5 @@ TEST_CASE("TestNotNullCustomPtrComparison") CHECK((NotNull1(p1) >= NotNull2(p2)) == (p1 >= p2)); CHECK((NotNull2(p2) >= NotNull1(p1)) == (p2 >= p1)); } + +static_assert(std::is_nothrow_move_constructible<not_null<void *>>::value, "not_null must be no-throw move constructible"); |