10 #include <type_traits>
11 #include <boost/mpl/less.hpp>
12 #include <boost/mpl/pop_front.hpp>
13 #include <boost/mpl/sort.hpp>
14 #include <boost/mpl/unique.hpp>
15 #include <boost/mpl/vector.hpp>
21 typedef boost::mpl::less<boost::mpl::sizeof_<boost::mpl::_>, boost::mpl::sizeof_<boost::mpl::_>>
Less;
22 typedef std::is_same<boost::mpl::_, boost::mpl::_>
Equal;
23 typedef typename boost::mpl::sort<T, Less>::type
Sorted;
24 typedef typename boost::mpl::unique<Sorted, Equal>::type
Unique;
28 template<std::size_t S,
typename Front,
typename... Tail>
31 typedef typename boost::mpl::copy<Front, boost::mpl::back_inserter<TailConcatenation>>
::type type;
33 template<
typename Front,
typename... Tail>
37 template<
typename... T>
42 template<bool,
typename Vector,
typename... Unpacked>
44 typedef typename boost::mpl::front<Vector>::type
Front;
45 typedef typename boost::mpl::pop_front<Vector>::type
Tail;
48 template<
typename Vector,
typename... Unpacked>
50 typedef boost::variant<Unpacked...>
type;
52 template<
typename Vector>
carl is the main namespace for the library.
std::is_same< boost::mpl::_, boost::mpl::_ > Equal
boost::mpl::sort< T, Less >::type Sorted
boost::mpl::unique< Sorted, Equal >::type Unique
boost::mpl::less< boost::mpl::sizeof_< boost::mpl::_ >, boost::mpl::sizeof_< boost::mpl::_ > > Less
boost::mpl::copy< Front, boost::mpl::back_inserter< TailConcatenation > >::type type
mpl_concatenate_impl< S-1, Tail... >::type TailConcatenation
mpl_concatenate_impl< sizeof...(T), T... >::type type
boost::mpl::pop_front< Vector >::type Tail
boost::mpl::front< Vector >::type Front
mpl_variant_of_impl< boost::mpl::empty< Tail >::value, Tail, Front, Unpacked... >::type type
boost::variant< Unpacked... > type
mpl_unique< Vector >::type Unique
mpl_variant_of_impl< boost::mpl::empty< Unique >::value, Unique >::type type