erase.hpp 1.2 KB

12345678910111213141516171819202122232425262728293031323334353637383940
  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_ERASE_10022005_1835)
  7. #define FUSION_ERASE_10022005_1835
  8. #include <boost/fusion/support/config.hpp>
  9. #include <boost/mpl/erase.hpp>
  10. #include <boost/fusion/support/tag_of.hpp>
  11. #include <boost/fusion/algorithm/transformation/erase.hpp>
  12. #include <boost/fusion/sequence/convert.hpp>
  13. namespace boost { namespace mpl
  14. {
  15. template <typename Tag>
  16. struct erase_impl;
  17. template <>
  18. struct erase_impl<fusion::fusion_sequence_tag>
  19. {
  20. template <typename Sequence, typename First, typename Last>
  21. struct apply
  22. {
  23. typedef typename
  24. fusion::result_of::erase<Sequence, First, Last>::type
  25. result;
  26. typedef typename
  27. fusion::result_of::convert<
  28. typename fusion::detail::tag_of<Sequence>::type, result>::type
  29. type;
  30. };
  31. };
  32. }}
  33. #endif