24 #ifndef STACK_HPP_INCLUDED
25 #define STACK_HPP_INCLUDED
37 template <
class Head = none,
class Tail = none>
40 typedef stack_impl type;
42 typedef stack_tag tag;
66 template <
class Stack>
67 struct stack_size :
integer<int, stack_size<typename Stack::tail>::type::value + 1> {};
70 struct stack_size<
empty_stack> : integer<int, 0> {};
73 struct size_impl<stack_tag>
76 struct apply : stack_size<Seq> {};
84 typedef typename Seq::head type;
90 struct begin_impl<stack_tag>
92 template <
class Stack>
97 struct end_impl<stack_tag>
99 template <
class Stack>
100 struct apply : stack_iterator<empty_stack> {};
104 struct clear_impl<stack_tag>
111 struct push_front_impl<stack_tag>
113 template <
class Stack,
class T>
114 struct apply : internal::stack_impl<T, Stack> {};
118 struct pop_front_impl<stack_tag>
120 template <
class Stack>
121 struct apply : Stack::tail {};