explicit_inst_slist_test.cpp 1.2 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344
  1. //////////////////////////////////////////////////////////////////////////////
  2. //
  3. // (C) Copyright Ion Gaztanaga 2015-2015. Distributed under the Boost
  4. // Software License, Version 1.0. (See accompanying file
  5. // LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
  6. //
  7. // See http://www.boost.org/libs/container for documentation.
  8. //
  9. //////////////////////////////////////////////////////////////////////////////
  10. #include <boost/container/slist.hpp>
  11. struct empty
  12. {
  13. friend bool operator == (const empty &, const empty &){ return true; }
  14. friend bool operator < (const empty &, const empty &){ return true; }
  15. };
  16. template class ::boost::container::slist<empty>;
  17. volatile ::boost::container::slist<empty> dummy;
  18. #include <boost/container/allocator.hpp>
  19. #include <boost/container/node_allocator.hpp>
  20. #include "movable_int.hpp"
  21. #include "dummy_test_allocator.hpp"
  22. namespace boost {
  23. namespace container {
  24. //Explicit instantiation to detect compilation errors
  25. template class boost::container::slist
  26. < test::movable_and_copyable_int
  27. , test::simple_allocator<test::movable_and_copyable_int> >;
  28. template class boost::container::slist
  29. < test::movable_and_copyable_int
  30. , node_allocator<test::movable_and_copyable_int> >;
  31. }}
  32. int main()
  33. {
  34. return 0;
  35. }