uses_optional.hpp 674 B

123456789101112131415161718192021222324252627282930313233
  1. // Copyright (C) 2023 Tim Blechmann
  2. //
  3. // Distributed under the Boost Software License, Version 1.0. (See
  4. // accompanying file LICENSE_1_0.txt or copy at
  5. // http://www.boost.org/LICENSE_1_0.txt)
  6. #ifndef BOOST_LOCKFREE_DETAIL_USES_OPTIONAL_HPP
  7. #define BOOST_LOCKFREE_DETAIL_USES_OPTIONAL_HPP
  8. #include <boost/config.hpp>
  9. #ifndef BOOST_NO_CXX17_HDR_OPTIONAL
  10. # include <optional>
  11. namespace boost { namespace lockfree {
  12. struct uses_optional_t
  13. {};
  14. # ifdef BOOST_NO_CXX17_INLINE_VARIABLES
  15. static
  16. # else
  17. inline
  18. # endif
  19. constexpr uses_optional_t uses_optional;
  20. }} // namespace boost::lockfree
  21. #endif
  22. #endif /* BOOST_LOCKFREE_DETAIL_USES_OPTIONAL_HPP */