/extlibs/Boost/include/boost/type_traits/add_cv.hpp

https://bitbucket.org/hugoruscitti/pilascpp · C++ Header · 48 lines · 19 code · 14 blank · 15 comment · 0 complexity · daac95f56a0ba94c3b7ef3adb5c22f80 MD5 · raw file

  1. // (C) Copyright Dave Abrahams, Steve Cleary, Beman Dawes, Howard
  2. // Hinnant & John Maddock 2000.
  3. // Use, modification and distribution are subject to the Boost Software License,
  4. // Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
  5. // http://www.boost.org/LICENSE_1_0.txt).
  6. //
  7. // See http://www.boost.org/libs/type_traits for most recent version including documentation.
  8. #ifndef BOOST_TT_ADD_CV_HPP_INCLUDED
  9. #define BOOST_TT_ADD_CV_HPP_INCLUDED
  10. #include <boost/config.hpp>
  11. // should be the last #include
  12. #include <boost/type_traits/detail/type_trait_def.hpp>
  13. namespace boost {
  14. // * convert a type T to a const volatile type - add_cv<T>
  15. // this is not required since the result is always
  16. // the same as "T const volatile", but it does suppress warnings
  17. // from some compilers:
  18. #if defined(BOOST_MSVC)
  19. // This bogus warning will appear when add_volatile is applied to a
  20. // const volatile reference because we can't detect const volatile
  21. // references with MSVC6.
  22. # pragma warning(push)
  23. # pragma warning(disable:4181) // warning C4181: qualifier applied to reference type ignored
  24. #endif
  25. BOOST_TT_AUX_TYPE_TRAIT_DEF1(add_cv,T,T const volatile)
  26. #if defined(BOOST_MSVC)
  27. # pragma warning(pop)
  28. #endif
  29. #ifndef BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION
  30. BOOST_TT_AUX_TYPE_TRAIT_PARTIAL_SPEC1_1(typename T,add_cv,T&,T&)
  31. #endif
  32. } // namespace boost
  33. #include <boost/type_traits/detail/type_trait_undef.hpp>
  34. #endif // BOOST_TT_ADD_CV_HPP_INCLUDED