at_impl.hpp 1.1 KB

123456789101112131415161718192021222324252627282930313233343536373839
  1. /*=============================================================================
  2. Copyright (c) 2001-2011 Joel de Guzman
  3. Copyright (c) 2005-2006 Dan Marsden
  4. Copyright (c) 2009-2010 Christopher Schmidt
  5. Distributed under the Boost Software License, Version 1.0. (See accompanying
  6. file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
  7. ==============================================================================*/
  8. #ifndef BOOST_FUSION_ADAPTED_STRUCT_DETAIL_AT_IMPL_HPP
  9. #define BOOST_FUSION_ADAPTED_STRUCT_DETAIL_AT_IMPL_HPP
  10. #include <boost/fusion/support/config.hpp>
  11. #include <boost/mpl/int.hpp>
  12. namespace boost { namespace fusion { namespace extension
  13. {
  14. template<typename>
  15. struct at_impl;
  16. template <>
  17. struct at_impl<struct_tag>
  18. {
  19. template <typename Seq, typename N>
  20. struct apply
  21. : access::struct_member<
  22. typename remove_const<Seq>::type
  23. , N::value
  24. >::template apply<Seq>
  25. {};
  26. };
  27. template <>
  28. struct at_impl<assoc_struct_tag>
  29. : at_impl<struct_tag>
  30. {};
  31. }}}
  32. #endif