config.hpp 1.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354
  1. // Boost.Range library
  2. //
  3. // Copyright Thorsten Ottosen 2003-2004. Use, modification and
  4. // distribution is subject to the Boost Software License, Version
  5. // 1.0. (See accompanying file LICENSE_1_0.txt or copy at
  6. // http://www.boost.org/LICENSE_1_0.txt)
  7. //
  8. // For more information, see http://www.boost.org/libs/range/
  9. //
  10. #ifndef BOOST_RANGE_CONFIG_HPP
  11. #define BOOST_RANGE_CONFIG_HPP
  12. #include <boost/detail/workaround.hpp>
  13. #if defined(_MSC_VER) && (_MSC_VER >= 1200)
  14. # pragma once
  15. #endif
  16. #include <boost/config.hpp>
  17. #ifdef BOOST_RANGE_DEDUCED_TYPENAME
  18. #error "macro already defined!"
  19. #endif
  20. #if BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x564))
  21. # define BOOST_RANGE_DEDUCED_TYPENAME typename
  22. #else
  23. # if BOOST_WORKAROUND(BOOST_MSVC, == 1300) && !defined(_MSC_EXTENSIONS)
  24. # define BOOST_RANGE_DEDUCED_TYPENAME typename
  25. # else
  26. # define BOOST_RANGE_DEDUCED_TYPENAME BOOST_DEDUCED_TYPENAME
  27. # endif
  28. #endif
  29. #ifdef BOOST_RANGE_NO_ARRAY_SUPPORT
  30. #error "macro already defined!"
  31. #endif
  32. #if BOOST_WORKAROUND( BOOST_MSVC, < 1300 ) || BOOST_WORKAROUND( __MWERKS__, <= 0x3003 )
  33. #define BOOST_RANGE_NO_ARRAY_SUPPORT 1
  34. #endif
  35. #ifdef BOOST_RANGE_NO_ARRAY_SUPPORT
  36. #define BOOST_RANGE_ARRAY_REF() (boost_range_array)
  37. #define BOOST_RANGE_NO_STATIC_ASSERT
  38. #else
  39. #define BOOST_RANGE_ARRAY_REF() (&boost_range_array)
  40. #endif
  41. #endif