2323
2424namespace msgpack {
2525
26+ /// @cond
2627MSGPACK_API_VERSION_NAMESPACE(v1) {
28+ /// @endcond
2729
2830namespace type {
2931
3032// FIXME operator==
3133// FIXME operator!=
3234<% GENERATION_LIMIT = 31 %>
3335
36+ /// @cond
3437template <typename A0<% 1 . upto ( GENERATION_LIMIT +1 ) { |i |%> , typename A <%= i %> <% } %> >
3538struct tuple;
39+ /// @endcond
3640
3741template < typename Tuple, int N >
3842struct tuple_element;
@@ -67,6 +71,7 @@ struct tuple_type<const T&> {
6771 typedef const T& transparent_reference;
6872};
6973
74+ /// @cond
7075<% 0 . upto ( GENERATION_LIMIT ) { |i |%>
7176<% 0 . upto ( i ) { |j |%>
7277template < typename A0<% 1 . upto ( i ) { |k |%> , typename A <%= k %> <% } %> >
@@ -91,13 +96,16 @@ private:
9196};
9297<% } %>
9398<% } %>
99+ /// @endcond
94100
95101template < >
96102struct tuple< > {
97103 tuple() {}
98104 tuple(msgpack::object const& o) { o.convert(*this); }
99105 typedef tuple< > value_type;
100106};
107+
108+ /// @cond
101109<% 0 . upto ( GENERATION_LIMIT ) { |i |%>
102110template < typename A0<% 1 . upto ( i ) { |j |%> , typename A <%= j %> <% } %> >
103111struct tuple< A0 <% 1 . upto ( i ) { |j |%> , A <%= j %> <% } %> > {
@@ -121,18 +129,22 @@ template <int N, typename A0<%1.upto(i) {|j|%>, typename A<%=j%><%}%>>
121129inline typename type::const_tuple_element< type::tuple < A0 <% 1 . upto ( i ) { |j |%> , A <%= j %> <% } %> > , N> ::const_reference get(type::tuple< A0 <% 1 . upto ( i ) { |j |%> , A <%= j %> <% } %> > const& t)
122130{ return t.template get< N > (); }
123131<% } %>
132+ /// @endcond
124133
125134inline tuple< > make_tuple()
126135{
127136 return tuple< > ();
128137}
138+
139+ /// @cond
129140<% 0 . upto ( GENERATION_LIMIT ) { |i |%>
130141template < typename A0<% 1 . upto ( i ) { |j |%> , typename A <%= j %> <% } %> >
131142inline tuple< A0 <% 1 . upto ( i ) { |j |%> , A <%= j %> <% } %> > make_tuple(typename tuple_type< A0 > ::transparent_reference a0<% 1 . upto ( i ) { |j |%> , typename tuple_type< A <%= j%> > ::transparent_reference a<%= j %> <% } %> )
132143{
133144 return tuple< A0 <% 1 . upto ( i ) { |j |%> , A <%= j %> <% } %> > (a0<% 1 . upto ( i ) { |j |%> , a<%= j %> <% } %> );
134145}
135146<% } %>
147+ /// @endcond
136148
137149} // namespace type
138150
@@ -142,6 +154,8 @@ inline msgpack::object const& operator>> (
142154 if(o.type != msgpack::type::ARRAY) { throw msgpack::type_error(); }
143155 return o;
144156}
157+
158+ /// @cond
145159<% 0 . upto ( GENERATION_LIMIT ) { |i |%>
146160template < typename A0<% 1 . upto ( i ) { |j |%> , typename A <%= j %> <% } %> >
147161inline msgpack::object const& operator> > (
@@ -154,6 +168,7 @@ inline msgpack::object const& operator>> (
154168 return o;
155169}
156170<% } %>
171+ /// @endcond
157172
158173template < typename Stream >
159174inline const msgpack::packer< Stream > & operator< < (
@@ -162,6 +177,8 @@ inline const msgpack::packer<Stream>& operator<< (
162177 o.pack_array(0);
163178 return o;
164179}
180+
181+ /// @cond
165182<% 0 . upto ( GENERATION_LIMIT ) { |i |%>
166183template < typename Stream, typename A0<% 1 . upto ( i ) { |j |%> , typename A <%= j %> <% } %> >
167184inline const msgpack::packer< Stream > & operator< < (
@@ -173,6 +190,7 @@ inline const msgpack::packer<Stream>& operator<< (
173190 return o;
174191}
175192<% } %>
193+ /// @endcond
176194
177195inline void operator< < (
178196 msgpack::object::with_zone& o,
@@ -181,6 +199,8 @@ inline void operator<< (
181199 o.via.array.ptr = nullptr;
182200 o.via.array.size = 0;
183201}
202+
203+ /// @cond
184204<% 0 . upto ( GENERATION_LIMIT ) { |i |%>
185205template < typename A0<% 1 . upto ( i ) { |j |%> , typename A <%= j %> <% } %> >
186206inline void operator< < (
@@ -193,8 +213,11 @@ inline void operator<< (
193213 o.via.array.ptr[<%= j%> ] = msgpack::object(v.template get< <%= j %> > (), o.zone);<% } %>
194214}
195215<% } %>
216+ /// @endcond
196217
218+ /// @cond
197219} // MSGPACK_API_VERSION_NAMESPACE(v1)
220+ /// @endcond
198221
199222} // namespace msgpack
200223
0 commit comments