queue.hpp 1.6 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546
  1. // Copyright (C) 2015 Vicente J. Botet Escriba
  2. //
  3. // Distributed under the Boost Software License, Version 1.0. (See accompanying
  4. // file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
  5. //
  6. // 2013/10 Vicente J. Botet Escriba
  7. // Creation.
  8. #if 0
  9. #ifndef BOOST_CSBL_QUEUE_HPP
  10. #define BOOST_CSBL_QUEUE_HPP
  11. #include <boost/config.hpp>
  12. // MSVC has some trouble instantiating a non_copyable type
  13. //C:\Program Files (x86)\Microsoft Visual Studio 11.0\VC\INCLUDE\xmemory0(606) : error C2248: 'non_copyable::non_copyable' : cannot access private member declared in class 'non_copyable'
  14. // ..\libs\thread\test\sync\mutual_exclusion\queue_views\single_thread_pass.cpp(24) : see declaration of 'non_copyable::non_copyable'
  15. // ..\libs\thread\test\sync\mutual_exclusion\queue_views\single_thread_pass.cpp(23) : see declaration of 'non_copyable'
  16. // C:\Program Files (x86)\Microsoft Visual Studio 11.0\VC\INCLUDE\xmemory0(605) : while compiling class template member function 'void std::allocator<_Ty>::construct(_Ty *,const _Ty &)'
  17. // with
  18. // [
  19. // _Ty=non_copyable
  20. // ]
  21. #if defined BOOST_THREAD_USES_BOOST_QUEUE || defined BOOST_NO_CXX11_RVALUE_REFERENCES || (defined _MSC_VER && _MSC_FULL_VER < 180020827)
  22. #ifndef BOOST_THREAD_USES_BOOST_QUEUE
  23. #define BOOST_THREAD_USES_BOOST_QUEUE
  24. #endif
  25. #include <boost/container/queue.hpp>
  26. #else
  27. #include <queue>
  28. #endif
  29. namespace boost
  30. {
  31. namespace csbl
  32. {
  33. #if defined BOOST_THREAD_USES_BOOST_QUEUE
  34. using ::boost::container::queue;
  35. #else
  36. using ::std::queue;
  37. #endif
  38. }
  39. }
  40. #endif // header
  41. #endif