1 /*============================================================================= 2 Copyright (c) 2001-2011 Joel de Guzman 3 4 Distributed under the Boost Software License, Version 1.0. (See accompanying 5 file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) 6 ==============================================================================*/ 7 #if !defined(FUSION_SET_09162005_1104) 8 #define FUSION_SET_09162005_1104 9 10 #include <boost/fusion/support/config.hpp> 11 #include <boost/fusion/support/is_sequence.hpp> 12 #include <boost/fusion/support/sequence_base.hpp> 13 #include <boost/fusion/support/category_of.hpp> 14 #include <boost/fusion/support/detail/access.hpp> 15 #include <boost/fusion/container/set/set_fwd.hpp> 16 #include <boost/fusion/container/set/detail/begin_impl.hpp> 17 #include <boost/fusion/container/set/detail/end_impl.hpp> 18 #include <boost/fusion/container/set/detail/value_of_impl.hpp> 19 #include <boost/fusion/container/set/detail/deref_data_impl.hpp> 20 #include <boost/fusion/container/set/detail/deref_impl.hpp> 21 #include <boost/fusion/container/set/detail/key_of_impl.hpp> 22 #include <boost/fusion/container/set/detail/value_of_data_impl.hpp> 23 #include <boost/fusion/container/vector/vector.hpp> 24 #include <boost/mpl/identity.hpp> 25 #include <boost/mpl/bool.hpp> 26 #include <boost/core/enable_if.hpp> 27 28 #if !defined(BOOST_FUSION_DONT_USE_PREPROCESSED_FILES) 29 #include <boost/fusion/container/set/detail/cpp03/preprocessed/set.hpp> 30 #else 31 #if defined(__WAVE__) && defined(BOOST_FUSION_CREATE_PREPROCESSED_FILES) 32 #pragma wave option(preserve: 2, line: 0, output: "preprocessed/set" FUSION_MAX_SET_SIZE_STR ".hpp") 33 #endif 34 35 /*============================================================================= 36 Copyright (c) 2001-2011 Joel de Guzman 37 38 Distributed under the Boost Software License, Version 1.0. (See accompanying 39 file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) 40 41 This is an auto-generated file. Do not edit! 42 ==============================================================================*/ 43 44 #if defined(__WAVE__) && defined(BOOST_FUSION_CREATE_PREPROCESSED_FILES) 45 #pragma wave option(preserve: 1) 46 #endif 47 48 namespace boost { namespace fusion 49 { 50 struct void_; 51 struct fusion_sequence_tag; 52 53 template <BOOST_PP_ENUM_PARAMS(FUSION_MAX_SET_SIZE, typename T)> 54 struct set : sequence_base<set<BOOST_PP_ENUM_PARAMS(FUSION_MAX_SET_SIZE, T)> > 55 { 56 struct category : forward_traversal_tag, associative_tag {}; 57 58 typedef set_tag fusion_tag; 59 typedef fusion_sequence_tag tag; // this gets picked up by MPL 60 typedef mpl::false_ is_view; 61 62 typedef vector< 63 BOOST_PP_ENUM_PARAMS(FUSION_MAX_SET_SIZE, T)> 64 storage_type; 65 66 typedef typename storage_type::size size; 67 68 BOOST_CONSTEXPR BOOST_FUSION_GPU_ENABLED setboost::fusion::set69 set() 70 : data() {} 71 72 template <typename Sequence> 73 BOOST_CONSTEXPR BOOST_FUSION_GPU_ENABLED setboost::fusion::set74 set(Sequence const& rhs 75 , typename boost::enable_if<traits::is_sequence<Sequence> >::type* = 0) 76 : data(rhs) {} 77 78 #include <boost/fusion/container/set/detail/cpp03/set_forward_ctor.hpp> 79 80 template <typename T> 81 BOOST_CXX14_CONSTEXPR BOOST_FUSION_GPU_ENABLED 82 set& operator =boost::fusion::set83 operator=(T const& rhs) 84 { 85 data = rhs; 86 return *this; 87 } 88 89 BOOST_CXX14_CONSTEXPR BOOST_FUSION_GPU_ENABLED get_databoost::fusion::set90 storage_type& get_data() { return data; } 91 BOOST_CONSTEXPR BOOST_FUSION_GPU_ENABLED get_databoost::fusion::set92 storage_type const& get_data() const { return data; } 93 94 private: 95 96 storage_type data; 97 }; 98 }} 99 100 #if defined(__WAVE__) && defined(BOOST_FUSION_CREATE_PREPROCESSED_FILES) 101 #pragma wave option(output: null) 102 #endif 103 104 #endif // BOOST_FUSION_DONT_USE_PREPROCESSED_FILES 105 106 #endif 107