end_impl.hpp 1.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142
  1. /*=============================================================================
  2. Copyright (c) 2001-2011 Joel de Guzman
  3. Distributed under the Boost Software License, Version 1.0. (See accompanying
  4. file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
  5. ==============================================================================*/
  6. #if !defined(FUSION_END_IMPL_05062005_1226)
  7. #define FUSION_END_IMPL_05062005_1226
  8. #include <boost/fusion/support/config.hpp>
  9. namespace boost { namespace fusion
  10. {
  11. struct iterator_range_tag;
  12. namespace extension
  13. {
  14. template <typename Tag>
  15. struct end_impl;
  16. template <>
  17. struct end_impl<iterator_range_tag>
  18. {
  19. template <typename Sequence>
  20. struct apply
  21. {
  22. typedef typename Sequence::end_type type;
  23. BOOST_CONSTEXPR BOOST_FUSION_GPU_ENABLED
  24. static type
  25. call(Sequence& s)
  26. {
  27. return s.last;
  28. }
  29. };
  30. };
  31. }
  32. }}
  33. #endif