list_to_cons.hpp 2.6 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576
  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_LIST_TO_CONS_07172005_1041)
  7. #define FUSION_LIST_TO_CONS_07172005_1041
  8. #include <boost/fusion/support/config.hpp>
  9. #include <boost/fusion/container/list/cons.hpp>
  10. #include <boost/fusion/container/list/detail/cpp03/limits.hpp>
  11. #include <boost/preprocessor/repetition/enum.hpp>
  12. #include <boost/preprocessor/repetition/enum_params.hpp>
  13. #include <boost/preprocessor/repetition/enum_shifted_params.hpp>
  14. #include <boost/preprocessor/arithmetic/dec.hpp>
  15. #define FUSION_VOID(z, n, _) void_
  16. namespace boost { namespace fusion
  17. {
  18. struct nil_;
  19. struct void_;
  20. }}
  21. #if !defined(BOOST_FUSION_DONT_USE_PREPROCESSED_FILES)
  22. #include <boost/fusion/container/list/detail/cpp03/preprocessed/list_to_cons.hpp>
  23. #else
  24. #if defined(__WAVE__) && defined(BOOST_FUSION_CREATE_PREPROCESSED_FILES)
  25. #pragma wave option(preserve: 2, line: 0, output: "preprocessed/list_to_cons" FUSION_MAX_LIST_SIZE_STR ".hpp")
  26. #endif
  27. /*=============================================================================
  28. Copyright (c) 2001-2011 Joel de Guzman
  29. Distributed under the Boost Software License, Version 1.0. (See accompanying
  30. file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
  31. This is an auto-generated file. Do not edit!
  32. ==============================================================================*/
  33. #if defined(__WAVE__) && defined(BOOST_FUSION_CREATE_PREPROCESSED_FILES)
  34. #pragma wave option(preserve: 1)
  35. #endif
  36. namespace boost { namespace fusion { namespace detail
  37. {
  38. template <BOOST_PP_ENUM_PARAMS(FUSION_MAX_LIST_SIZE, typename T)>
  39. struct list_to_cons
  40. {
  41. typedef T0 head_type;
  42. typedef list_to_cons<
  43. BOOST_PP_ENUM_SHIFTED_PARAMS(FUSION_MAX_LIST_SIZE, T), void_>
  44. tail_list_to_cons;
  45. typedef typename tail_list_to_cons::type tail_type;
  46. typedef cons<head_type, tail_type> type;
  47. #include <boost/fusion/container/list/detail/cpp03/list_to_cons_call.hpp>
  48. };
  49. template <>
  50. struct list_to_cons<BOOST_PP_ENUM(FUSION_MAX_LIST_SIZE, FUSION_VOID, _)>
  51. {
  52. typedef nil_ type;
  53. };
  54. }}}
  55. #if defined(__WAVE__) && defined(BOOST_FUSION_CREATE_PREPROCESSED_FILES)
  56. #pragma wave option(output: null)
  57. #endif
  58. #endif // BOOST_FUSION_DONT_USE_PREPROCESSED_FILES
  59. #undef FUSION_VOID
  60. #endif