| 1 | /* |
|---|---|
| 2 | Copyright 2020 Glen Joseph Fernandes |
| 3 | (glenjofe@gmail.com) |
| 4 | |
| 5 | Distributed under the Boost Software License, Version 1.0. |
| 6 | (http://www.boost.org/LICENSE_1_0.txt) |
| 7 | */ |
| 8 | #include <boost/core/allocator_access.hpp> |
| 9 | #include <boost/core/lightweight_test_trait.hpp> |
| 10 | |
| 11 | template<class T> |
| 12 | struct A1 { |
| 13 | typedef T value_type; |
| 14 | }; |
| 15 | |
| 16 | template<class T> |
| 17 | struct A2 { |
| 18 | typedef T value_type; |
| 19 | struct propagate_on_container_move_assignment { |
| 20 | static const bool value = true; |
| 21 | }; |
| 22 | }; |
| 23 | |
| 24 | int main() |
| 25 | { |
| 26 | BOOST_TEST_TRAIT_FALSE((boost:: |
| 27 | allocator_propagate_on_container_move_assignment<A1<int> >::type)); |
| 28 | BOOST_TEST_TRAIT_TRUE((boost:: |
| 29 | allocator_propagate_on_container_move_assignment<A2<int> >::type)); |
| 30 | return boost::report_errors(); |
| 31 | } |
| 32 |
