Chris@16
|
1
|
Chris@16
|
2 // Copyright Peter Dimov 2001
|
Chris@16
|
3 // Copyright Aleksey Gurtovoy 2001-2004
|
Chris@16
|
4 //
|
Chris@16
|
5 // Distributed under the Boost Software License, Version 1.0.
|
Chris@16
|
6 // (See accompanying file LICENSE_1_0.txt or copy at
|
Chris@16
|
7 // http://www.boost.org/LICENSE_1_0.txt)
|
Chris@16
|
8 //
|
Chris@16
|
9
|
Chris@16
|
10 // Preprocessed version of "boost/mpl/bind.hpp" header
|
Chris@16
|
11 // -- DO NOT modify by hand!
|
Chris@16
|
12
|
Chris@16
|
13 namespace boost { namespace mpl {
|
Chris@16
|
14
|
Chris@16
|
15 namespace aux {
|
Chris@16
|
16 template< bool >
|
Chris@16
|
17 struct resolve_arg_impl
|
Chris@16
|
18 {
|
Chris@16
|
19 template<
|
Chris@16
|
20 typename T, typename U1, typename U2, typename U3
|
Chris@16
|
21 , typename U4, typename U5
|
Chris@16
|
22 >
|
Chris@16
|
23 struct result_
|
Chris@16
|
24 {
|
Chris@16
|
25 typedef T type;
|
Chris@16
|
26 };
|
Chris@16
|
27 };
|
Chris@16
|
28
|
Chris@16
|
29 template<>
|
Chris@16
|
30 struct resolve_arg_impl<true>
|
Chris@16
|
31 {
|
Chris@16
|
32 template<
|
Chris@16
|
33 typename T, typename U1, typename U2, typename U3
|
Chris@16
|
34 , typename U4, typename U5
|
Chris@16
|
35 >
|
Chris@16
|
36 struct result_
|
Chris@16
|
37 {
|
Chris@16
|
38 typedef typename apply_wrap5<
|
Chris@16
|
39 T
|
Chris@16
|
40 , U1, U2, U3, U4, U5
|
Chris@16
|
41 >::type type;
|
Chris@16
|
42 };
|
Chris@16
|
43 };
|
Chris@16
|
44
|
Chris@16
|
45 template< typename T > struct is_bind_template;
|
Chris@16
|
46
|
Chris@16
|
47 template<
|
Chris@16
|
48 typename T, typename U1, typename U2, typename U3, typename U4
|
Chris@16
|
49 , typename U5
|
Chris@16
|
50 >
|
Chris@16
|
51 struct resolve_bind_arg
|
Chris@16
|
52 : resolve_arg_impl< is_bind_template<T>::value >
|
Chris@16
|
53 ::template result_< T,U1,U2,U3,U4,U5 >
|
Chris@16
|
54 {
|
Chris@16
|
55 };
|
Chris@16
|
56
|
Chris@16
|
57 template< typename T >
|
Chris@16
|
58 struct replace_unnamed_arg_impl
|
Chris@16
|
59 {
|
Chris@16
|
60 template< typename Arg > struct result_
|
Chris@16
|
61 {
|
Chris@16
|
62 typedef Arg next;
|
Chris@16
|
63 typedef T type;
|
Chris@16
|
64 };
|
Chris@16
|
65 };
|
Chris@16
|
66
|
Chris@16
|
67 template<>
|
Chris@16
|
68 struct replace_unnamed_arg_impl< arg< -1 > >
|
Chris@16
|
69 {
|
Chris@16
|
70 template< typename Arg > struct result_
|
Chris@16
|
71 {
|
Chris@16
|
72 typedef typename next<Arg>::type next;
|
Chris@16
|
73 typedef Arg type;
|
Chris@16
|
74 };
|
Chris@16
|
75 };
|
Chris@16
|
76
|
Chris@16
|
77 template< typename T, typename Arg >
|
Chris@16
|
78 struct replace_unnamed_arg
|
Chris@16
|
79 : replace_unnamed_arg_impl<T>::template result_<Arg>
|
Chris@16
|
80 {
|
Chris@16
|
81 };
|
Chris@16
|
82
|
Chris@16
|
83 template< int arity_ > struct bind_chooser;
|
Chris@16
|
84
|
Chris@16
|
85 aux::no_tag is_bind_helper(...);
|
Chris@16
|
86 template< typename T > aux::no_tag is_bind_helper(protect<T>*);
|
Chris@16
|
87
|
Chris@16
|
88 template< int N >
|
Chris@16
|
89 aux::yes_tag is_bind_helper(arg<N>*);
|
Chris@16
|
90
|
Chris@16
|
91 template< bool is_ref_ = true >
|
Chris@16
|
92 struct is_bind_template_impl
|
Chris@16
|
93 {
|
Chris@16
|
94 template< typename T > struct result_
|
Chris@16
|
95 {
|
Chris@16
|
96 BOOST_STATIC_CONSTANT(bool, value = false);
|
Chris@16
|
97 };
|
Chris@16
|
98 };
|
Chris@16
|
99
|
Chris@16
|
100 template<>
|
Chris@16
|
101 struct is_bind_template_impl<false>
|
Chris@16
|
102 {
|
Chris@16
|
103 template< typename T > struct result_
|
Chris@16
|
104 {
|
Chris@16
|
105 BOOST_STATIC_CONSTANT(bool, value =
|
Chris@16
|
106 sizeof(aux::is_bind_helper(static_cast<T*>(0)))
|
Chris@16
|
107 == sizeof(aux::yes_tag)
|
Chris@16
|
108 );
|
Chris@16
|
109 };
|
Chris@16
|
110 };
|
Chris@16
|
111
|
Chris@16
|
112 template< typename T > struct is_bind_template
|
Chris@16
|
113 : is_bind_template_impl< ::boost::detail::is_reference_impl<T>::value >
|
Chris@16
|
114 ::template result_<T>
|
Chris@16
|
115 {
|
Chris@16
|
116 };
|
Chris@16
|
117
|
Chris@16
|
118 } // namespace aux
|
Chris@16
|
119
|
Chris@16
|
120 template<
|
Chris@16
|
121 typename F
|
Chris@16
|
122 >
|
Chris@16
|
123 struct bind0
|
Chris@16
|
124 {
|
Chris@16
|
125 template<
|
Chris@16
|
126 typename U1 = na, typename U2 = na, typename U3 = na
|
Chris@16
|
127 , typename U4 = na, typename U5 = na
|
Chris@16
|
128 >
|
Chris@16
|
129 struct apply
|
Chris@16
|
130 {
|
Chris@16
|
131 private:
|
Chris@16
|
132 typedef aux::replace_unnamed_arg< F, mpl::arg<1> > r0;
|
Chris@16
|
133 typedef typename r0::type a0;
|
Chris@16
|
134 typedef typename r0::next n1;
|
Chris@16
|
135 typedef typename aux::resolve_bind_arg< a0,U1,U2,U3,U4,U5 >::type f_;
|
Chris@16
|
136 ///
|
Chris@16
|
137 public:
|
Chris@16
|
138 typedef typename apply_wrap0<
|
Chris@16
|
139 f_
|
Chris@16
|
140 >::type type;
|
Chris@16
|
141
|
Chris@16
|
142 };
|
Chris@16
|
143 };
|
Chris@16
|
144
|
Chris@16
|
145 namespace aux {
|
Chris@16
|
146
|
Chris@16
|
147 template<
|
Chris@16
|
148 typename F
|
Chris@16
|
149 >
|
Chris@16
|
150 aux::yes_tag
|
Chris@16
|
151 is_bind_helper(bind0<F>*);
|
Chris@16
|
152
|
Chris@16
|
153 } // namespace aux
|
Chris@16
|
154
|
Chris@16
|
155 BOOST_MPL_AUX_ARITY_SPEC(1, bind0)
|
Chris@16
|
156 BOOST_MPL_AUX_TEMPLATE_ARITY_SPEC(1, bind0)
|
Chris@16
|
157
|
Chris@16
|
158 template<
|
Chris@16
|
159 typename F, typename T1
|
Chris@16
|
160 >
|
Chris@16
|
161 struct bind1
|
Chris@16
|
162 {
|
Chris@16
|
163 template<
|
Chris@16
|
164 typename U1 = na, typename U2 = na, typename U3 = na
|
Chris@16
|
165 , typename U4 = na, typename U5 = na
|
Chris@16
|
166 >
|
Chris@16
|
167 struct apply
|
Chris@16
|
168 {
|
Chris@16
|
169 private:
|
Chris@16
|
170 typedef aux::replace_unnamed_arg< F, mpl::arg<1> > r0;
|
Chris@16
|
171 typedef typename r0::type a0;
|
Chris@16
|
172 typedef typename r0::next n1;
|
Chris@16
|
173 typedef typename aux::resolve_bind_arg< a0,U1,U2,U3,U4,U5 >::type f_;
|
Chris@16
|
174 ///
|
Chris@16
|
175 typedef aux::replace_unnamed_arg< T1,n1 > r1;
|
Chris@16
|
176 typedef typename r1::type a1;
|
Chris@16
|
177 typedef typename r1::next n2;
|
Chris@16
|
178 typedef aux::resolve_bind_arg< a1,U1,U2,U3,U4,U5 > t1;
|
Chris@16
|
179 ///
|
Chris@16
|
180 public:
|
Chris@16
|
181 typedef typename apply_wrap1<
|
Chris@16
|
182 f_
|
Chris@16
|
183 , typename t1::type
|
Chris@16
|
184 >::type type;
|
Chris@16
|
185
|
Chris@16
|
186 };
|
Chris@16
|
187 };
|
Chris@16
|
188
|
Chris@16
|
189 namespace aux {
|
Chris@16
|
190
|
Chris@16
|
191 template<
|
Chris@16
|
192 typename F, typename T1
|
Chris@16
|
193 >
|
Chris@16
|
194 aux::yes_tag
|
Chris@16
|
195 is_bind_helper(bind1< F,T1 >*);
|
Chris@16
|
196
|
Chris@16
|
197 } // namespace aux
|
Chris@16
|
198
|
Chris@16
|
199 BOOST_MPL_AUX_ARITY_SPEC(2, bind1)
|
Chris@16
|
200 BOOST_MPL_AUX_TEMPLATE_ARITY_SPEC(2, bind1)
|
Chris@16
|
201
|
Chris@16
|
202 template<
|
Chris@16
|
203 typename F, typename T1, typename T2
|
Chris@16
|
204 >
|
Chris@16
|
205 struct bind2
|
Chris@16
|
206 {
|
Chris@16
|
207 template<
|
Chris@16
|
208 typename U1 = na, typename U2 = na, typename U3 = na
|
Chris@16
|
209 , typename U4 = na, typename U5 = na
|
Chris@16
|
210 >
|
Chris@16
|
211 struct apply
|
Chris@16
|
212 {
|
Chris@16
|
213 private:
|
Chris@16
|
214 typedef aux::replace_unnamed_arg< F, mpl::arg<1> > r0;
|
Chris@16
|
215 typedef typename r0::type a0;
|
Chris@16
|
216 typedef typename r0::next n1;
|
Chris@16
|
217 typedef typename aux::resolve_bind_arg< a0,U1,U2,U3,U4,U5 >::type f_;
|
Chris@16
|
218 ///
|
Chris@16
|
219 typedef aux::replace_unnamed_arg< T1,n1 > r1;
|
Chris@16
|
220 typedef typename r1::type a1;
|
Chris@16
|
221 typedef typename r1::next n2;
|
Chris@16
|
222 typedef aux::resolve_bind_arg< a1,U1,U2,U3,U4,U5 > t1;
|
Chris@16
|
223 ///
|
Chris@16
|
224 typedef aux::replace_unnamed_arg< T2,n2 > r2;
|
Chris@16
|
225 typedef typename r2::type a2;
|
Chris@16
|
226 typedef typename r2::next n3;
|
Chris@16
|
227 typedef aux::resolve_bind_arg< a2,U1,U2,U3,U4,U5 > t2;
|
Chris@16
|
228 ///
|
Chris@16
|
229 public:
|
Chris@16
|
230 typedef typename apply_wrap2<
|
Chris@16
|
231 f_
|
Chris@16
|
232 , typename t1::type, typename t2::type
|
Chris@16
|
233 >::type type;
|
Chris@16
|
234
|
Chris@16
|
235 };
|
Chris@16
|
236 };
|
Chris@16
|
237
|
Chris@16
|
238 namespace aux {
|
Chris@16
|
239
|
Chris@16
|
240 template<
|
Chris@16
|
241 typename F, typename T1, typename T2
|
Chris@16
|
242 >
|
Chris@16
|
243 aux::yes_tag
|
Chris@16
|
244 is_bind_helper(bind2< F,T1,T2 >*);
|
Chris@16
|
245
|
Chris@16
|
246 } // namespace aux
|
Chris@16
|
247
|
Chris@16
|
248 BOOST_MPL_AUX_ARITY_SPEC(3, bind2)
|
Chris@16
|
249 BOOST_MPL_AUX_TEMPLATE_ARITY_SPEC(3, bind2)
|
Chris@16
|
250
|
Chris@16
|
251 template<
|
Chris@16
|
252 typename F, typename T1, typename T2, typename T3
|
Chris@16
|
253 >
|
Chris@16
|
254 struct bind3
|
Chris@16
|
255 {
|
Chris@16
|
256 template<
|
Chris@16
|
257 typename U1 = na, typename U2 = na, typename U3 = na
|
Chris@16
|
258 , typename U4 = na, typename U5 = na
|
Chris@16
|
259 >
|
Chris@16
|
260 struct apply
|
Chris@16
|
261 {
|
Chris@16
|
262 private:
|
Chris@16
|
263 typedef aux::replace_unnamed_arg< F, mpl::arg<1> > r0;
|
Chris@16
|
264 typedef typename r0::type a0;
|
Chris@16
|
265 typedef typename r0::next n1;
|
Chris@16
|
266 typedef typename aux::resolve_bind_arg< a0,U1,U2,U3,U4,U5 >::type f_;
|
Chris@16
|
267 ///
|
Chris@16
|
268 typedef aux::replace_unnamed_arg< T1,n1 > r1;
|
Chris@16
|
269 typedef typename r1::type a1;
|
Chris@16
|
270 typedef typename r1::next n2;
|
Chris@16
|
271 typedef aux::resolve_bind_arg< a1,U1,U2,U3,U4,U5 > t1;
|
Chris@16
|
272 ///
|
Chris@16
|
273 typedef aux::replace_unnamed_arg< T2,n2 > r2;
|
Chris@16
|
274 typedef typename r2::type a2;
|
Chris@16
|
275 typedef typename r2::next n3;
|
Chris@16
|
276 typedef aux::resolve_bind_arg< a2,U1,U2,U3,U4,U5 > t2;
|
Chris@16
|
277 ///
|
Chris@16
|
278 typedef aux::replace_unnamed_arg< T3,n3 > r3;
|
Chris@16
|
279 typedef typename r3::type a3;
|
Chris@16
|
280 typedef typename r3::next n4;
|
Chris@16
|
281 typedef aux::resolve_bind_arg< a3,U1,U2,U3,U4,U5 > t3;
|
Chris@16
|
282 ///
|
Chris@16
|
283 public:
|
Chris@16
|
284 typedef typename apply_wrap3<
|
Chris@16
|
285 f_
|
Chris@16
|
286 , typename t1::type, typename t2::type, typename t3::type
|
Chris@16
|
287 >::type type;
|
Chris@16
|
288
|
Chris@16
|
289 };
|
Chris@16
|
290 };
|
Chris@16
|
291
|
Chris@16
|
292 namespace aux {
|
Chris@16
|
293
|
Chris@16
|
294 template<
|
Chris@16
|
295 typename F, typename T1, typename T2, typename T3
|
Chris@16
|
296 >
|
Chris@16
|
297 aux::yes_tag
|
Chris@16
|
298 is_bind_helper(bind3< F,T1,T2,T3 >*);
|
Chris@16
|
299
|
Chris@16
|
300 } // namespace aux
|
Chris@16
|
301
|
Chris@16
|
302 BOOST_MPL_AUX_ARITY_SPEC(4, bind3)
|
Chris@16
|
303 BOOST_MPL_AUX_TEMPLATE_ARITY_SPEC(4, bind3)
|
Chris@16
|
304
|
Chris@16
|
305 template<
|
Chris@16
|
306 typename F, typename T1, typename T2, typename T3, typename T4
|
Chris@16
|
307 >
|
Chris@16
|
308 struct bind4
|
Chris@16
|
309 {
|
Chris@16
|
310 template<
|
Chris@16
|
311 typename U1 = na, typename U2 = na, typename U3 = na
|
Chris@16
|
312 , typename U4 = na, typename U5 = na
|
Chris@16
|
313 >
|
Chris@16
|
314 struct apply
|
Chris@16
|
315 {
|
Chris@16
|
316 private:
|
Chris@16
|
317 typedef aux::replace_unnamed_arg< F, mpl::arg<1> > r0;
|
Chris@16
|
318 typedef typename r0::type a0;
|
Chris@16
|
319 typedef typename r0::next n1;
|
Chris@16
|
320 typedef typename aux::resolve_bind_arg< a0,U1,U2,U3,U4,U5 >::type f_;
|
Chris@16
|
321 ///
|
Chris@16
|
322 typedef aux::replace_unnamed_arg< T1,n1 > r1;
|
Chris@16
|
323 typedef typename r1::type a1;
|
Chris@16
|
324 typedef typename r1::next n2;
|
Chris@16
|
325 typedef aux::resolve_bind_arg< a1,U1,U2,U3,U4,U5 > t1;
|
Chris@16
|
326 ///
|
Chris@16
|
327 typedef aux::replace_unnamed_arg< T2,n2 > r2;
|
Chris@16
|
328 typedef typename r2::type a2;
|
Chris@16
|
329 typedef typename r2::next n3;
|
Chris@16
|
330 typedef aux::resolve_bind_arg< a2,U1,U2,U3,U4,U5 > t2;
|
Chris@16
|
331 ///
|
Chris@16
|
332 typedef aux::replace_unnamed_arg< T3,n3 > r3;
|
Chris@16
|
333 typedef typename r3::type a3;
|
Chris@16
|
334 typedef typename r3::next n4;
|
Chris@16
|
335 typedef aux::resolve_bind_arg< a3,U1,U2,U3,U4,U5 > t3;
|
Chris@16
|
336 ///
|
Chris@16
|
337 typedef aux::replace_unnamed_arg< T4,n4 > r4;
|
Chris@16
|
338 typedef typename r4::type a4;
|
Chris@16
|
339 typedef typename r4::next n5;
|
Chris@16
|
340 typedef aux::resolve_bind_arg< a4,U1,U2,U3,U4,U5 > t4;
|
Chris@16
|
341 ///
|
Chris@16
|
342 public:
|
Chris@16
|
343 typedef typename apply_wrap4<
|
Chris@16
|
344 f_
|
Chris@16
|
345 , typename t1::type, typename t2::type, typename t3::type
|
Chris@16
|
346 , typename t4::type
|
Chris@16
|
347 >::type type;
|
Chris@16
|
348
|
Chris@16
|
349 };
|
Chris@16
|
350 };
|
Chris@16
|
351
|
Chris@16
|
352 namespace aux {
|
Chris@16
|
353
|
Chris@16
|
354 template<
|
Chris@16
|
355 typename F, typename T1, typename T2, typename T3, typename T4
|
Chris@16
|
356 >
|
Chris@16
|
357 aux::yes_tag
|
Chris@16
|
358 is_bind_helper(bind4< F,T1,T2,T3,T4 >*);
|
Chris@16
|
359
|
Chris@16
|
360 } // namespace aux
|
Chris@16
|
361
|
Chris@16
|
362 BOOST_MPL_AUX_ARITY_SPEC(5, bind4)
|
Chris@16
|
363 BOOST_MPL_AUX_TEMPLATE_ARITY_SPEC(5, bind4)
|
Chris@16
|
364
|
Chris@16
|
365 template<
|
Chris@16
|
366 typename F, typename T1, typename T2, typename T3, typename T4
|
Chris@16
|
367 , typename T5
|
Chris@16
|
368 >
|
Chris@16
|
369 struct bind5
|
Chris@16
|
370 {
|
Chris@16
|
371 template<
|
Chris@16
|
372 typename U1 = na, typename U2 = na, typename U3 = na
|
Chris@16
|
373 , typename U4 = na, typename U5 = na
|
Chris@16
|
374 >
|
Chris@16
|
375 struct apply
|
Chris@16
|
376 {
|
Chris@16
|
377 private:
|
Chris@16
|
378 typedef aux::replace_unnamed_arg< F, mpl::arg<1> > r0;
|
Chris@16
|
379 typedef typename r0::type a0;
|
Chris@16
|
380 typedef typename r0::next n1;
|
Chris@16
|
381 typedef typename aux::resolve_bind_arg< a0,U1,U2,U3,U4,U5 >::type f_;
|
Chris@16
|
382 ///
|
Chris@16
|
383 typedef aux::replace_unnamed_arg< T1,n1 > r1;
|
Chris@16
|
384 typedef typename r1::type a1;
|
Chris@16
|
385 typedef typename r1::next n2;
|
Chris@16
|
386 typedef aux::resolve_bind_arg< a1,U1,U2,U3,U4,U5 > t1;
|
Chris@16
|
387 ///
|
Chris@16
|
388 typedef aux::replace_unnamed_arg< T2,n2 > r2;
|
Chris@16
|
389 typedef typename r2::type a2;
|
Chris@16
|
390 typedef typename r2::next n3;
|
Chris@16
|
391 typedef aux::resolve_bind_arg< a2,U1,U2,U3,U4,U5 > t2;
|
Chris@16
|
392 ///
|
Chris@16
|
393 typedef aux::replace_unnamed_arg< T3,n3 > r3;
|
Chris@16
|
394 typedef typename r3::type a3;
|
Chris@16
|
395 typedef typename r3::next n4;
|
Chris@16
|
396 typedef aux::resolve_bind_arg< a3,U1,U2,U3,U4,U5 > t3;
|
Chris@16
|
397 ///
|
Chris@16
|
398 typedef aux::replace_unnamed_arg< T4,n4 > r4;
|
Chris@16
|
399 typedef typename r4::type a4;
|
Chris@16
|
400 typedef typename r4::next n5;
|
Chris@16
|
401 typedef aux::resolve_bind_arg< a4,U1,U2,U3,U4,U5 > t4;
|
Chris@16
|
402 ///
|
Chris@16
|
403 typedef aux::replace_unnamed_arg< T5,n5 > r5;
|
Chris@16
|
404 typedef typename r5::type a5;
|
Chris@16
|
405 typedef typename r5::next n6;
|
Chris@16
|
406 typedef aux::resolve_bind_arg< a5,U1,U2,U3,U4,U5 > t5;
|
Chris@16
|
407 ///
|
Chris@16
|
408 public:
|
Chris@16
|
409 typedef typename apply_wrap5<
|
Chris@16
|
410 f_
|
Chris@16
|
411 , typename t1::type, typename t2::type, typename t3::type
|
Chris@16
|
412 , typename t4::type, typename t5::type
|
Chris@16
|
413 >::type type;
|
Chris@16
|
414
|
Chris@16
|
415 };
|
Chris@16
|
416 };
|
Chris@16
|
417
|
Chris@16
|
418 namespace aux {
|
Chris@16
|
419
|
Chris@16
|
420 template<
|
Chris@16
|
421 typename F, typename T1, typename T2, typename T3, typename T4
|
Chris@16
|
422 , typename T5
|
Chris@16
|
423 >
|
Chris@16
|
424 aux::yes_tag
|
Chris@16
|
425 is_bind_helper(bind5< F,T1,T2,T3,T4,T5 >*);
|
Chris@16
|
426
|
Chris@16
|
427 } // namespace aux
|
Chris@16
|
428
|
Chris@16
|
429 BOOST_MPL_AUX_ARITY_SPEC(6, bind5)
|
Chris@16
|
430 BOOST_MPL_AUX_TEMPLATE_ARITY_SPEC(6, bind5)
|
Chris@16
|
431 }}
|
Chris@16
|
432
|