9
3

has_upper_bound.hpp 1.3 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647
  1. // Copyright 2005 Daniel Wallin.
  2. // Copyright 2005 Joel de Guzman.
  3. //
  4. // Use, modification and distribution is subject to the Boost Software
  5. // License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
  6. // http://www.boost.org/LICENSE_1_0.txt)
  7. //
  8. // Modeled after range_ex, Copyright 2004 Eric Niebler
  9. ///////////////////////////////////////////////////////////////////////////////
  10. //
  11. // has_upper_bound.hpp
  12. //
  13. /////////////////////////////////////////////////////////////////////////////
  14. #ifndef BOOST_PHOENIX_HAS_UPPER_BOUND_EN_14_12_2004
  15. #define BOOST_PHOENIX_HAS_UPPER_BOUND_EN_14_12_2004
  16. #include <boost/mpl/or.hpp>
  17. #include "./is_std_map.hpp"
  18. #include "./is_std_set.hpp"
  19. #include "./is_std_hash_map.hpp"
  20. #include "./is_std_hash_set.hpp"
  21. namespace boost
  22. {
  23. // Specialize this for user-defined types
  24. template<typename T>
  25. struct has_upper_bound
  26. : boost::mpl::or_<
  27. boost::mpl::or_<
  28. is_std_map<T>
  29. , is_std_multimap<T>
  30. , is_std_set<T>
  31. , is_std_multiset<T>
  32. >
  33. , boost::mpl::or_<
  34. is_std_hash_map<T>
  35. , is_std_hash_multimap<T>
  36. , is_std_hash_set<T>
  37. , is_std_hash_multiset<T>
  38. >
  39. >
  40. {
  41. };
  42. }
  43. #endif