os/ossrv/ossrv_pub/boost_apis/boost/spirit/phoenix/casts.hpp
author sl@SLION-WIN7.fritz.box
Fri, 15 Jun 2012 03:10:57 +0200
changeset 0 bde4ae8d615e
permissions -rw-r--r--
First public contribution.
sl@0
     1
/*=============================================================================
sl@0
     2
    Phoenix V1.2.1
sl@0
     3
    Copyright (c) 2001-2003 Joel de Guzman
sl@0
     4
    Copyright (c) 2001-2003 Hartmut Kaiser
sl@0
     5
sl@0
     6
    Use, modification and distribution is subject to the Boost Software
sl@0
     7
    License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
sl@0
     8
    http://www.boost.org/LICENSE_1_0.txt)
sl@0
     9
==============================================================================*/
sl@0
    10
sl@0
    11
#ifndef PHOENIX_CASTS_HPP
sl@0
    12
#define PHOENIX_CASTS_HPP
sl@0
    13
sl@0
    14
///////////////////////////////////////////////////////////////////////////////
sl@0
    15
#include <boost/spirit/phoenix/actor.hpp>
sl@0
    16
#include <boost/spirit/phoenix/composite.hpp>
sl@0
    17
#include <boost/static_assert.hpp>
sl@0
    18
sl@0
    19
///////////////////////////////////////////////////////////////////////////////
sl@0
    20
namespace phoenix {
sl@0
    21
sl@0
    22
///////////////////////////////////////////////////////////////////////////////
sl@0
    23
//
sl@0
    24
//  Phoenix predefined maximum construct_ limit. This limit defines the maximum
sl@0
    25
//  number of parameters supported for calles to the set of construct_ template
sl@0
    26
//  functions (lazy object construction, see below). This number defaults to 3.
sl@0
    27
//  The actual maximum is rounded up in multiples of 3. Thus, if this value
sl@0
    28
//  is 4, the actual limit is 6. The ultimate maximum limit in this
sl@0
    29
//  implementation is 15.
sl@0
    30
//  PHOENIX_CONSTRUCT_LIMIT should NOT be greater than PHOENIX_LIMIT!
sl@0
    31
sl@0
    32
#if !defined(PHOENIX_CONSTRUCT_LIMIT)
sl@0
    33
#define PHOENIX_CONSTRUCT_LIMIT PHOENIX_LIMIT
sl@0
    34
#endif
sl@0
    35
sl@0
    36
// ensure PHOENIX_CONSTRUCT_LIMIT <= PHOENIX_LIMIT
sl@0
    37
BOOST_STATIC_ASSERT(PHOENIX_CONSTRUCT_LIMIT <= PHOENIX_LIMIT);
sl@0
    38
sl@0
    39
// ensure PHOENIX_CONSTRUCT_LIMIT <= 15
sl@0
    40
BOOST_STATIC_ASSERT(PHOENIX_CONSTRUCT_LIMIT <= 15);
sl@0
    41
sl@0
    42
///////////////////////////////////////////////////////////////////////////////
sl@0
    43
//
sl@0
    44
//  Lazy C++ casts
sl@0
    45
//
sl@0
    46
//      The set of lazy C++ cast template classes and functions provide a way
sl@0
    47
//      of lazily casting certain type to another during parsing.
sl@0
    48
//      The lazy C++ templates are (syntactically) used very much like
sl@0
    49
//      the well known C++ casts:
sl@0
    50
//
sl@0
    51
//          A *a = static_cast_<A *>(...actor returning a convertible type...);
sl@0
    52
//
sl@0
    53
//      where the given parameter should be an actor, which eval() function
sl@0
    54
//      returns a convertible type.
sl@0
    55
//
sl@0
    56
///////////////////////////////////////////////////////////////////////////////
sl@0
    57
template <typename T, typename A>
sl@0
    58
struct static_cast_l {
sl@0
    59
sl@0
    60
    template <typename TupleT>
sl@0
    61
    struct result { typedef T type; };
sl@0
    62
sl@0
    63
    static_cast_l(A const& a_)
sl@0
    64
    :   a(a_) {}
sl@0
    65
sl@0
    66
    template <typename TupleT>
sl@0
    67
    T
sl@0
    68
    eval(TupleT const& args) const
sl@0
    69
    {
sl@0
    70
        return static_cast<T>(a.eval(args));
sl@0
    71
    }
sl@0
    72
sl@0
    73
    A a;
sl@0
    74
};
sl@0
    75
sl@0
    76
//////////////////////////////////
sl@0
    77
template <typename T, typename BaseAT>
sl@0
    78
inline actor<static_cast_l<T, BaseAT> >
sl@0
    79
static_cast_(actor<BaseAT> const& a)
sl@0
    80
{
sl@0
    81
    typedef static_cast_l<T, BaseAT> cast_t;
sl@0
    82
    return actor<cast_t>(cast_t(a));
sl@0
    83
}
sl@0
    84
sl@0
    85
//////////////////////////////////
sl@0
    86
template <typename T, typename A>
sl@0
    87
struct dynamic_cast_l {
sl@0
    88
sl@0
    89
    template <typename TupleT>
sl@0
    90
    struct result { typedef T type; };
sl@0
    91
sl@0
    92
    dynamic_cast_l(A const& a_)
sl@0
    93
    :   a(a_) {}
sl@0
    94
sl@0
    95
    template <typename TupleT>
sl@0
    96
    T
sl@0
    97
    eval(TupleT const& args) const
sl@0
    98
    {
sl@0
    99
        return dynamic_cast<T>(a.eval(args));
sl@0
   100
    }
sl@0
   101
sl@0
   102
    A a;
sl@0
   103
};
sl@0
   104
sl@0
   105
//////////////////////////////////
sl@0
   106
template <typename T, typename BaseAT>
sl@0
   107
inline actor<dynamic_cast_l<T, BaseAT> >
sl@0
   108
dynamic_cast_(actor<BaseAT> const& a)
sl@0
   109
{
sl@0
   110
    typedef dynamic_cast_l<T, BaseAT> cast_t;
sl@0
   111
    return actor<cast_t>(cast_t(a));
sl@0
   112
}
sl@0
   113
sl@0
   114
//////////////////////////////////
sl@0
   115
template <typename T, typename A>
sl@0
   116
struct reinterpret_cast_l {
sl@0
   117
sl@0
   118
    template <typename TupleT>
sl@0
   119
    struct result { typedef T type; };
sl@0
   120
sl@0
   121
    reinterpret_cast_l(A const& a_)
sl@0
   122
    :   a(a_) {}
sl@0
   123
sl@0
   124
    template <typename TupleT>
sl@0
   125
    T
sl@0
   126
    eval(TupleT const& args) const
sl@0
   127
    {
sl@0
   128
        return reinterpret_cast<T>(a.eval(args));
sl@0
   129
    }
sl@0
   130
sl@0
   131
    A a;
sl@0
   132
};
sl@0
   133
sl@0
   134
//////////////////////////////////
sl@0
   135
template <typename T, typename BaseAT>
sl@0
   136
inline actor<reinterpret_cast_l<T, BaseAT> >
sl@0
   137
reinterpret_cast_(actor<BaseAT> const& a)
sl@0
   138
{
sl@0
   139
    typedef reinterpret_cast_l<T, BaseAT> cast_t;
sl@0
   140
    return actor<cast_t>(cast_t(a));
sl@0
   141
}
sl@0
   142
sl@0
   143
//////////////////////////////////
sl@0
   144
template <typename T, typename A>
sl@0
   145
struct const_cast_l {
sl@0
   146
sl@0
   147
    template <typename TupleT>
sl@0
   148
    struct result { typedef T type; };
sl@0
   149
sl@0
   150
    const_cast_l(A const& a_)
sl@0
   151
    :   a(a_) {}
sl@0
   152
sl@0
   153
    template <typename TupleT>
sl@0
   154
    T
sl@0
   155
    eval(TupleT const& args) const
sl@0
   156
    {
sl@0
   157
        return const_cast<T>(a.eval(args));
sl@0
   158
    }
sl@0
   159
sl@0
   160
    A a;
sl@0
   161
};
sl@0
   162
sl@0
   163
//////////////////////////////////
sl@0
   164
template <typename T, typename BaseAT>
sl@0
   165
inline actor<const_cast_l<T, BaseAT> >
sl@0
   166
const_cast_(actor<BaseAT> const& a)
sl@0
   167
{
sl@0
   168
    typedef const_cast_l<T, BaseAT> cast_t;
sl@0
   169
    return actor<cast_t>(cast_t(a));
sl@0
   170
}
sl@0
   171
sl@0
   172
///////////////////////////////////////////////////////////////////////////////
sl@0
   173
//
sl@0
   174
//  construct_
sl@0
   175
//
sl@0
   176
//      Lazy object construction
sl@0
   177
//
sl@0
   178
//      The set of construct_<> template classes and functions provide a way
sl@0
   179
//      of lazily constructing certain object from a arbitrary set of
sl@0
   180
//      actors during parsing.
sl@0
   181
//      The construct_ templates are (syntactically) used very much like
sl@0
   182
//      the well known C++ casts:
sl@0
   183
//
sl@0
   184
//          A a = construct_<A>(...arbitrary list of actors...);
sl@0
   185
//
sl@0
   186
//      where the given parameters are submitted as parameters to the
sl@0
   187
//      contructor of the object of type A. (This certainly implies, that
sl@0
   188
//      type A has a constructor with a fitting set of parameter types
sl@0
   189
//      defined.)
sl@0
   190
//
sl@0
   191
//      The maximum number of needed parameters is controlled through the
sl@0
   192
//      preprocessor constant PHOENIX_CONSTRUCT_LIMIT. Note though, that this
sl@0
   193
//      limit should not be greater than PHOENIX_LIMIT.
sl@0
   194
//
sl@0
   195
///////////////////////////////////////////////////////////////////////////////
sl@0
   196
template <typename T>
sl@0
   197
struct construct_l_0 {
sl@0
   198
    typedef T result_type;
sl@0
   199
sl@0
   200
    T operator()() const {
sl@0
   201
        return T();
sl@0
   202
    }
sl@0
   203
};
sl@0
   204
sl@0
   205
sl@0
   206
template <typename T>
sl@0
   207
struct construct_l {
sl@0
   208
sl@0
   209
    template <
sl@0
   210
            typename A
sl@0
   211
        ,   typename B
sl@0
   212
        ,   typename C
sl@0
   213
sl@0
   214
#if PHOENIX_CONSTRUCT_LIMIT > 3
sl@0
   215
        ,   typename D
sl@0
   216
        ,   typename E
sl@0
   217
        ,   typename F
sl@0
   218
sl@0
   219
#if PHOENIX_CONSTRUCT_LIMIT > 6
sl@0
   220
        ,   typename G
sl@0
   221
        ,   typename H
sl@0
   222
        ,   typename I
sl@0
   223
sl@0
   224
#if PHOENIX_CONSTRUCT_LIMIT > 9
sl@0
   225
        ,   typename J
sl@0
   226
        ,   typename K
sl@0
   227
        ,   typename L
sl@0
   228
sl@0
   229
#if PHOENIX_CONSTRUCT_LIMIT > 12
sl@0
   230
        ,   typename M
sl@0
   231
        ,   typename N
sl@0
   232
        ,   typename O
sl@0
   233
#endif
sl@0
   234
#endif
sl@0
   235
#endif
sl@0
   236
#endif
sl@0
   237
    >
sl@0
   238
    struct result { typedef T type; };
sl@0
   239
sl@0
   240
    T operator()() const 
sl@0
   241
    {
sl@0
   242
        return T();
sl@0
   243
    }
sl@0
   244
sl@0
   245
    template <typename A>
sl@0
   246
    T operator()(A const& a) const 
sl@0
   247
    {
sl@0
   248
        T t(a); 
sl@0
   249
        return t;
sl@0
   250
    }
sl@0
   251
sl@0
   252
    template <typename A, typename B>
sl@0
   253
    T operator()(A const& a, B const& b) const 
sl@0
   254
    {
sl@0
   255
        T t(a, b);
sl@0
   256
        return t;
sl@0
   257
    }
sl@0
   258
sl@0
   259
    template <typename A, typename B, typename C>
sl@0
   260
    T operator()(A const& a, B const& b, C const& c) const 
sl@0
   261
    {
sl@0
   262
        T t(a, b, c);
sl@0
   263
        return t;
sl@0
   264
    }
sl@0
   265
sl@0
   266
#if PHOENIX_CONSTRUCT_LIMIT > 3
sl@0
   267
    template <
sl@0
   268
        typename A, typename B, typename C, typename D
sl@0
   269
    >
sl@0
   270
    T operator()(
sl@0
   271
        A const& a, B const& b, C const& c, D const& d) const
sl@0
   272
    {
sl@0
   273
        T t(a, b, c, d);
sl@0
   274
        return t;
sl@0
   275
    }
sl@0
   276
sl@0
   277
    template <
sl@0
   278
        typename A, typename B, typename C, typename D, typename E
sl@0
   279
    >
sl@0
   280
    T operator()(
sl@0
   281
        A const& a, B const& b, C const& c, D const& d, E const& e) const
sl@0
   282
    {
sl@0
   283
        T t(a, b, c, d, e);
sl@0
   284
        return t;
sl@0
   285
    }
sl@0
   286
sl@0
   287
    template <
sl@0
   288
        typename A, typename B, typename C, typename D, typename E,
sl@0
   289
        typename F
sl@0
   290
    >
sl@0
   291
    T operator()(
sl@0
   292
        A const& a, B const& b, C const& c, D const& d, E const& e,
sl@0
   293
        F const& f) const
sl@0
   294
    {
sl@0
   295
        T t(a, b, c, d, e, f);
sl@0
   296
        return t;
sl@0
   297
    }
sl@0
   298
sl@0
   299
#if PHOENIX_CONSTRUCT_LIMIT > 6
sl@0
   300
    template <
sl@0
   301
        typename A, typename B, typename C, typename D, typename E,
sl@0
   302
        typename F, typename G
sl@0
   303
    >
sl@0
   304
    T operator()(
sl@0
   305
        A const& a, B const& b, C const& c, D const& d, E const& e,
sl@0
   306
        F const& f, G const& g) const
sl@0
   307
    {
sl@0
   308
        T t(a, b, c, d, e, f, g);
sl@0
   309
        return t;
sl@0
   310
    }
sl@0
   311
sl@0
   312
    template <
sl@0
   313
        typename A, typename B, typename C, typename D, typename E,
sl@0
   314
        typename F, typename G, typename H
sl@0
   315
    >
sl@0
   316
    T operator()(
sl@0
   317
        A const& a, B const& b, C const& c, D const& d, E const& e,
sl@0
   318
        F const& f, G const& g, H const& h) const
sl@0
   319
    {
sl@0
   320
        T t(a, b, c, d, e, f, g, h);
sl@0
   321
        return t;
sl@0
   322
    }
sl@0
   323
sl@0
   324
    template <
sl@0
   325
        typename A, typename B, typename C, typename D, typename E,
sl@0
   326
        typename F, typename G, typename H, typename I
sl@0
   327
    >
sl@0
   328
    T operator()(
sl@0
   329
        A const& a, B const& b, C const& c, D const& d, E const& e,
sl@0
   330
        F const& f, G const& g, H const& h, I const& i) const
sl@0
   331
    {
sl@0
   332
        T t(a, b, c, d, e, f, g, h, i);
sl@0
   333
        return t;
sl@0
   334
    }
sl@0
   335
sl@0
   336
#if PHOENIX_CONSTRUCT_LIMIT > 9
sl@0
   337
    template <
sl@0
   338
        typename A, typename B, typename C, typename D, typename E,
sl@0
   339
        typename F, typename G, typename H, typename I, typename J
sl@0
   340
    >
sl@0
   341
    T operator()(
sl@0
   342
        A const& a, B const& b, C const& c, D const& d, E const& e,
sl@0
   343
        F const& f, G const& g, H const& h, I const& i, J const& j) const
sl@0
   344
    {
sl@0
   345
        T t(a, b, c, d, e, f, g, h, i, j);
sl@0
   346
        return t;
sl@0
   347
    }
sl@0
   348
sl@0
   349
    template <
sl@0
   350
        typename A, typename B, typename C, typename D, typename E,
sl@0
   351
        typename F, typename G, typename H, typename I, typename J,
sl@0
   352
        typename K
sl@0
   353
    >
sl@0
   354
    T operator()(
sl@0
   355
        A const& a, B const& b, C const& c, D const& d, E const& e,
sl@0
   356
        F const& f, G const& g, H const& h, I const& i, J const& j,
sl@0
   357
        K const& k) const
sl@0
   358
    {
sl@0
   359
        T t(a, b, c, d, e, f, g, h, i, j, k);
sl@0
   360
        return t;
sl@0
   361
    }
sl@0
   362
sl@0
   363
    template <
sl@0
   364
        typename A, typename B, typename C, typename D, typename E,
sl@0
   365
        typename F, typename G, typename H, typename I, typename J,
sl@0
   366
        typename K, typename L
sl@0
   367
    >
sl@0
   368
    T operator()(
sl@0
   369
        A const& a, B const& b, C const& c, D const& d, E const& e,
sl@0
   370
        F const& f, G const& g, H const& h, I const& i, J const& j,
sl@0
   371
        K const& k, L const& l) const
sl@0
   372
    {
sl@0
   373
        T t(a, b, c, d, e, f, g, h, i, j, k, l);
sl@0
   374
        return t;
sl@0
   375
    }
sl@0
   376
sl@0
   377
#if PHOENIX_CONSTRUCT_LIMIT > 12
sl@0
   378
    template <
sl@0
   379
        typename A, typename B, typename C, typename D, typename E,
sl@0
   380
        typename F, typename G, typename H, typename I, typename J,
sl@0
   381
        typename K, typename L, typename M
sl@0
   382
    >
sl@0
   383
    T operator()(
sl@0
   384
        A const& a, B const& b, C const& c, D const& d, E const& e,
sl@0
   385
        F const& f, G const& g, H const& h, I const& i, J const& j,
sl@0
   386
        K const& k, L const& l, M const& m) const
sl@0
   387
    {
sl@0
   388
        T t(a, b, c, d, e, f, g, h, i, j, k, l, m);
sl@0
   389
        return t;
sl@0
   390
    }
sl@0
   391
sl@0
   392
    template <
sl@0
   393
        typename A, typename B, typename C, typename D, typename E,
sl@0
   394
        typename F, typename G, typename H, typename I, typename J,
sl@0
   395
        typename K, typename L, typename M, typename N
sl@0
   396
    >
sl@0
   397
    T operator()(
sl@0
   398
        A const& a, B const& b, C const& c, D const& d, E const& e,
sl@0
   399
        F const& f, G const& g, H const& h, I const& i, J const& j,
sl@0
   400
        K const& k, L const& l, M const& m, N const& n) const
sl@0
   401
    {
sl@0
   402
        T t(a, b, c, d, e, f, g, h, i, j, k, l, m, n);
sl@0
   403
        return t;
sl@0
   404
    }
sl@0
   405
sl@0
   406
    template <
sl@0
   407
        typename A, typename B, typename C, typename D, typename E,
sl@0
   408
        typename F, typename G, typename H, typename I, typename J,
sl@0
   409
        typename K, typename L, typename M, typename N, typename O
sl@0
   410
    >
sl@0
   411
    T operator()(
sl@0
   412
        A const& a, B const& b, C const& c, D const& d, E const& e,
sl@0
   413
        F const& f, G const& g, H const& h, I const& i, J const& j,
sl@0
   414
        K const& k, L const& l, M const& m, N const& n, O const& o) const
sl@0
   415
    {
sl@0
   416
        T t(a, b, c, d, e, f, g, h, i, j, k, l, m, n, o);
sl@0
   417
        return t;
sl@0
   418
    }
sl@0
   419
sl@0
   420
#endif
sl@0
   421
#endif
sl@0
   422
#endif
sl@0
   423
#endif
sl@0
   424
};
sl@0
   425
sl@0
   426
sl@0
   427
template <typename T>
sl@0
   428
struct construct_1 {
sl@0
   429
sl@0
   430
    template <
sl@0
   431
            typename A
sl@0
   432
    >
sl@0
   433
    struct result { typedef T type; };
sl@0
   434
sl@0
   435
    template <typename A>
sl@0
   436
    T operator()(A const& a) const 
sl@0
   437
    {
sl@0
   438
        T t(a);
sl@0
   439
        return t;
sl@0
   440
    }
sl@0
   441
sl@0
   442
};
sl@0
   443
sl@0
   444
template <typename T>
sl@0
   445
struct construct_2 {
sl@0
   446
sl@0
   447
    template <
sl@0
   448
            typename A
sl@0
   449
        ,   typename B
sl@0
   450
    >
sl@0
   451
    struct result { typedef T type; };
sl@0
   452
sl@0
   453
    template <typename A, typename B>
sl@0
   454
    T operator()(A const& a, B const& b) const 
sl@0
   455
    {
sl@0
   456
        T t(a, b);
sl@0
   457
        return t;
sl@0
   458
    }
sl@0
   459
sl@0
   460
};
sl@0
   461
sl@0
   462
template <typename T>
sl@0
   463
struct construct_3 {
sl@0
   464
sl@0
   465
    template <
sl@0
   466
            typename A
sl@0
   467
        ,   typename B
sl@0
   468
        ,   typename C
sl@0
   469
    >
sl@0
   470
    struct result { typedef T type; };
sl@0
   471
sl@0
   472
    template <typename A, typename B, typename C>
sl@0
   473
    T operator()(A const& a, B const& b, C const& c) const 
sl@0
   474
    {
sl@0
   475
        T t(a, b, c);
sl@0
   476
        return t;
sl@0
   477
    }
sl@0
   478
};
sl@0
   479
sl@0
   480
#if PHOENIX_CONSTRUCT_LIMIT > 3
sl@0
   481
template <typename T>
sl@0
   482
struct construct_4 {
sl@0
   483
sl@0
   484
    template <
sl@0
   485
            typename A
sl@0
   486
        ,   typename B
sl@0
   487
        ,   typename C
sl@0
   488
        ,   typename D
sl@0
   489
    >
sl@0
   490
    struct result { typedef T type; };
sl@0
   491
sl@0
   492
    template <
sl@0
   493
        typename A, typename B, typename C, typename D
sl@0
   494
    >
sl@0
   495
    T operator()(
sl@0
   496
        A const& a, B const& b, C const& c, D const& d) const
sl@0
   497
    {
sl@0
   498
        T t(a, b, c, d);
sl@0
   499
        return t;
sl@0
   500
    }
sl@0
   501
};
sl@0
   502
sl@0
   503
sl@0
   504
template <typename T>
sl@0
   505
struct construct_5 {
sl@0
   506
sl@0
   507
    template <
sl@0
   508
            typename A
sl@0
   509
        ,   typename B
sl@0
   510
        ,   typename C
sl@0
   511
        ,   typename D
sl@0
   512
        ,   typename E
sl@0
   513
    >
sl@0
   514
    struct result { typedef T type; };
sl@0
   515
sl@0
   516
    template <
sl@0
   517
        typename A, typename B, typename C, typename D, typename E
sl@0
   518
    >
sl@0
   519
    T operator()(
sl@0
   520
        A const& a, B const& b, C const& c, D const& d, E const& e) const
sl@0
   521
    {
sl@0
   522
        T t(a, b, c, d, e);
sl@0
   523
        return t;
sl@0
   524
    }
sl@0
   525
};
sl@0
   526
sl@0
   527
sl@0
   528
template <typename T>
sl@0
   529
struct construct_6 {
sl@0
   530
sl@0
   531
    template <
sl@0
   532
            typename A
sl@0
   533
        ,   typename B
sl@0
   534
        ,   typename C
sl@0
   535
        ,   typename D
sl@0
   536
        ,   typename E
sl@0
   537
        ,   typename F
sl@0
   538
    >
sl@0
   539
    struct result { typedef T type; };
sl@0
   540
sl@0
   541
    template <
sl@0
   542
        typename A, typename B, typename C, typename D, typename E,
sl@0
   543
        typename F
sl@0
   544
    >
sl@0
   545
    T operator()(
sl@0
   546
        A const& a, B const& b, C const& c, D const& d, E const& e,
sl@0
   547
        F const& f) const
sl@0
   548
    {
sl@0
   549
        T t(a, b, c, d, e, f);
sl@0
   550
        return t;
sl@0
   551
    }
sl@0
   552
};
sl@0
   553
#endif
sl@0
   554
sl@0
   555
sl@0
   556
#if PHOENIX_CONSTRUCT_LIMIT > 6
sl@0
   557
template <typename T>
sl@0
   558
struct construct_7 {
sl@0
   559
sl@0
   560
    template <
sl@0
   561
            typename A
sl@0
   562
        ,   typename B
sl@0
   563
        ,   typename C
sl@0
   564
        ,   typename D
sl@0
   565
        ,   typename E
sl@0
   566
        ,   typename F
sl@0
   567
        ,   typename G
sl@0
   568
    >
sl@0
   569
    struct result { typedef T type; };
sl@0
   570
sl@0
   571
    template <
sl@0
   572
        typename A, typename B, typename C, typename D, typename E,
sl@0
   573
        typename F, typename G
sl@0
   574
    >
sl@0
   575
    T operator()(
sl@0
   576
        A const& a, B const& b, C const& c, D const& d, E const& e,
sl@0
   577
        F const& f, G const& g) const
sl@0
   578
    {
sl@0
   579
        T t(a, b, c, d, e, f, g);
sl@0
   580
        return t;
sl@0
   581
    }
sl@0
   582
};
sl@0
   583
sl@0
   584
template <typename T>
sl@0
   585
struct construct_8 {
sl@0
   586
sl@0
   587
    template <
sl@0
   588
            typename A
sl@0
   589
        ,   typename B
sl@0
   590
        ,   typename C
sl@0
   591
        ,   typename D
sl@0
   592
        ,   typename E
sl@0
   593
        ,   typename F
sl@0
   594
        ,   typename G
sl@0
   595
        ,   typename H
sl@0
   596
    >
sl@0
   597
    struct result { typedef T type; };
sl@0
   598
sl@0
   599
    template <
sl@0
   600
        typename A, typename B, typename C, typename D, typename E,
sl@0
   601
        typename F, typename G, typename H
sl@0
   602
    >
sl@0
   603
    T operator()(
sl@0
   604
        A const& a, B const& b, C const& c, D const& d, E const& e,
sl@0
   605
        F const& f, G const& g, H const& h) const
sl@0
   606
    {
sl@0
   607
        T t(a, b, c, d, e, f, g, h);
sl@0
   608
        return t;
sl@0
   609
    }
sl@0
   610
};
sl@0
   611
sl@0
   612
template <typename T>
sl@0
   613
struct construct_9 {
sl@0
   614
sl@0
   615
    template <
sl@0
   616
            typename A
sl@0
   617
        ,   typename B
sl@0
   618
        ,   typename C
sl@0
   619
        ,   typename D
sl@0
   620
        ,   typename E
sl@0
   621
        ,   typename F
sl@0
   622
        ,   typename G
sl@0
   623
        ,   typename H
sl@0
   624
        ,   typename I
sl@0
   625
    >
sl@0
   626
    struct result { typedef T type; };
sl@0
   627
sl@0
   628
    template <
sl@0
   629
        typename A, typename B, typename C, typename D, typename E,
sl@0
   630
        typename F, typename G, typename H, typename I
sl@0
   631
    >
sl@0
   632
    T operator()(
sl@0
   633
        A const& a, B const& b, C const& c, D const& d, E const& e,
sl@0
   634
        F const& f, G const& g, H const& h, I const& i) const
sl@0
   635
    {
sl@0
   636
        T t(a, b, c, d, e, f, g, h, i);
sl@0
   637
        return t;
sl@0
   638
    }
sl@0
   639
};
sl@0
   640
#endif
sl@0
   641
sl@0
   642
sl@0
   643
#if PHOENIX_CONSTRUCT_LIMIT > 9
sl@0
   644
template <typename T>
sl@0
   645
struct construct_10 {
sl@0
   646
sl@0
   647
    template <
sl@0
   648
            typename A
sl@0
   649
        ,   typename B
sl@0
   650
        ,   typename C
sl@0
   651
        ,   typename D
sl@0
   652
        ,   typename E
sl@0
   653
        ,   typename F
sl@0
   654
        ,   typename G
sl@0
   655
        ,   typename H
sl@0
   656
        ,   typename I
sl@0
   657
        ,   typename J
sl@0
   658
    >
sl@0
   659
    struct result { typedef T type; };
sl@0
   660
sl@0
   661
    template <
sl@0
   662
        typename A, typename B, typename C, typename D, typename E,
sl@0
   663
        typename F, typename G, typename H, typename I, typename J
sl@0
   664
    >
sl@0
   665
    T operator()(
sl@0
   666
        A const& a, B const& b, C const& c, D const& d, E const& e,
sl@0
   667
        F const& f, G const& g, H const& h, I const& i, J const& j) const
sl@0
   668
    {
sl@0
   669
        T t(a, b, c, d, e, f, g, h, i, j);
sl@0
   670
        return t;
sl@0
   671
    }
sl@0
   672
};
sl@0
   673
sl@0
   674
template <typename T>
sl@0
   675
struct construct_11 {
sl@0
   676
sl@0
   677
    template <
sl@0
   678
            typename A
sl@0
   679
        ,   typename B
sl@0
   680
        ,   typename C
sl@0
   681
        ,   typename D
sl@0
   682
        ,   typename E
sl@0
   683
        ,   typename F
sl@0
   684
        ,   typename G
sl@0
   685
        ,   typename H
sl@0
   686
        ,   typename I
sl@0
   687
        ,   typename J
sl@0
   688
        ,   typename K
sl@0
   689
    >
sl@0
   690
    struct result { typedef T type; };
sl@0
   691
sl@0
   692
    template <
sl@0
   693
        typename A, typename B, typename C, typename D, typename E,
sl@0
   694
        typename F, typename G, typename H, typename I, typename J,
sl@0
   695
        typename K
sl@0
   696
    >
sl@0
   697
    T operator()(
sl@0
   698
        A const& a, B const& b, C const& c, D const& d, E const& e,
sl@0
   699
        F const& f, G const& g, H const& h, I const& i, J const& j,
sl@0
   700
        K const& k) const
sl@0
   701
    {
sl@0
   702
        T t(a, b, c, d, e, f, g, h, i, j, k);
sl@0
   703
        return t;
sl@0
   704
    }
sl@0
   705
};
sl@0
   706
sl@0
   707
template <typename T>
sl@0
   708
struct construct_12 {
sl@0
   709
sl@0
   710
    template <
sl@0
   711
            typename A
sl@0
   712
        ,   typename B
sl@0
   713
        ,   typename C
sl@0
   714
        ,   typename D
sl@0
   715
        ,   typename E
sl@0
   716
        ,   typename F
sl@0
   717
        ,   typename G
sl@0
   718
        ,   typename H
sl@0
   719
        ,   typename I
sl@0
   720
        ,   typename J
sl@0
   721
        ,   typename K
sl@0
   722
        ,   typename L
sl@0
   723
    >
sl@0
   724
    struct result { typedef T type; };
sl@0
   725
sl@0
   726
    template <
sl@0
   727
        typename A, typename B, typename C, typename D, typename E,
sl@0
   728
        typename F, typename G, typename H, typename I, typename J,
sl@0
   729
        typename K, typename L
sl@0
   730
    >
sl@0
   731
    T operator()(
sl@0
   732
        A const& a, B const& b, C const& c, D const& d, E const& e,
sl@0
   733
        F const& f, G const& g, H const& h, I const& i, J const& j,
sl@0
   734
        K const& k, L const& l) const
sl@0
   735
    {
sl@0
   736
        T t(a, b, c, d, f, e, g, h, i, j, k, l);
sl@0
   737
        return t;
sl@0
   738
    }
sl@0
   739
};
sl@0
   740
#endif
sl@0
   741
sl@0
   742
#if PHOENIX_CONSTRUCT_LIMIT > 12
sl@0
   743
template <typename T>
sl@0
   744
struct construct_13 {
sl@0
   745
sl@0
   746
    template <
sl@0
   747
            typename A
sl@0
   748
        ,   typename B
sl@0
   749
        ,   typename C
sl@0
   750
        ,   typename D
sl@0
   751
        ,   typename E
sl@0
   752
        ,   typename F
sl@0
   753
        ,   typename G
sl@0
   754
        ,   typename H
sl@0
   755
        ,   typename I
sl@0
   756
        ,   typename J
sl@0
   757
        ,   typename K
sl@0
   758
        ,   typename L
sl@0
   759
        ,   typename M
sl@0
   760
    >
sl@0
   761
    struct result { typedef T type; };
sl@0
   762
sl@0
   763
    template <
sl@0
   764
        typename A, typename B, typename C, typename D, typename E,
sl@0
   765
        typename F, typename G, typename H, typename I, typename J,
sl@0
   766
        typename K, typename L, typename M
sl@0
   767
    >
sl@0
   768
    T operator()(
sl@0
   769
        A const& a, B const& b, C const& c, D const& d, E const& e,
sl@0
   770
        F const& f, G const& g, H const& h, I const& i, J const& j,
sl@0
   771
        K const& k, L const& l, M const& m) const
sl@0
   772
    {
sl@0
   773
        T t(a, b, c, d, e, f, g, h, i, j, k, l, m);
sl@0
   774
        return t;
sl@0
   775
    }
sl@0
   776
};
sl@0
   777
sl@0
   778
template <typename T>
sl@0
   779
struct construct_14 {
sl@0
   780
sl@0
   781
    template <
sl@0
   782
            typename A
sl@0
   783
        ,   typename B
sl@0
   784
        ,   typename C
sl@0
   785
        ,   typename D
sl@0
   786
        ,   typename E
sl@0
   787
        ,   typename F
sl@0
   788
        ,   typename G
sl@0
   789
        ,   typename H
sl@0
   790
        ,   typename I
sl@0
   791
        ,   typename J
sl@0
   792
        ,   typename K
sl@0
   793
        ,   typename L
sl@0
   794
        ,   typename M
sl@0
   795
        ,   typename N
sl@0
   796
    >
sl@0
   797
    struct result { typedef T type; };
sl@0
   798
sl@0
   799
    template <
sl@0
   800
        typename A, typename B, typename C, typename D, typename E,
sl@0
   801
        typename F, typename G, typename H, typename I, typename J,
sl@0
   802
        typename K, typename L, typename M, typename N
sl@0
   803
    >
sl@0
   804
    T operator()(
sl@0
   805
        A const& a, B const& b, C const& c, D const& d, E const& e,
sl@0
   806
        F const& f, G const& g, H const& h, I const& i, J const& j,
sl@0
   807
        K const& k, L const& l, M const& m, N const& n) const
sl@0
   808
    {
sl@0
   809
        T t(a, b, c, d, e, f, g, h, i, j, k, l, m, n);
sl@0
   810
        return t;
sl@0
   811
    }
sl@0
   812
};
sl@0
   813
sl@0
   814
template <typename T>
sl@0
   815
struct construct_15 {
sl@0
   816
sl@0
   817
    template <
sl@0
   818
            typename A
sl@0
   819
        ,   typename B
sl@0
   820
        ,   typename C
sl@0
   821
        ,   typename D
sl@0
   822
        ,   typename E
sl@0
   823
        ,   typename F
sl@0
   824
        ,   typename G
sl@0
   825
        ,   typename H
sl@0
   826
        ,   typename I
sl@0
   827
        ,   typename J
sl@0
   828
        ,   typename K
sl@0
   829
        ,   typename L
sl@0
   830
        ,   typename M
sl@0
   831
        ,   typename N
sl@0
   832
        ,   typename O
sl@0
   833
    >
sl@0
   834
    struct result { typedef T type; };
sl@0
   835
sl@0
   836
    template <
sl@0
   837
        typename A, typename B, typename C, typename D, typename E,
sl@0
   838
        typename F, typename G, typename H, typename I, typename J,
sl@0
   839
        typename K, typename L, typename M, typename N, typename O
sl@0
   840
    >
sl@0
   841
    T operator()(
sl@0
   842
        A const& a, B const& b, C const& c, D const& d, E const& e,
sl@0
   843
        F const& f, G const& g, H const& h, I const& i, J const& j,
sl@0
   844
        K const& k, L const& l, M const& m, N const& n, O const& o) const
sl@0
   845
    {
sl@0
   846
        T t(a, b, c, d, f, e, g, h, i, j, k, l, m, n, o);
sl@0
   847
        return t;
sl@0
   848
    }
sl@0
   849
};
sl@0
   850
#endif
sl@0
   851
sl@0
   852
sl@0
   853
#if defined(__BORLANDC__) || (defined(__MWERKS__) && (__MWERKS__ <= 0x3002))
sl@0
   854
sl@0
   855
///////////////////////////////////////////////////////////////////////////////
sl@0
   856
//
sl@0
   857
//  The following specializations are needed because Borland and CodeWarrior
sl@0
   858
//  does not accept default template arguments in nested template classes in
sl@0
   859
//  classes (i.e construct_l::result)
sl@0
   860
//
sl@0
   861
///////////////////////////////////////////////////////////////////////////////
sl@0
   862
template <typename T, typename TupleT>
sl@0
   863
struct composite0_result<construct_l_0<T>, TupleT> {
sl@0
   864
sl@0
   865
    typedef T type;
sl@0
   866
};
sl@0
   867
sl@0
   868
//////////////////////////////////
sl@0
   869
template <typename T, typename TupleT,
sl@0
   870
    typename A>
sl@0
   871
struct composite1_result<construct_l<T>, TupleT, A> {
sl@0
   872
sl@0
   873
    typedef T type;
sl@0
   874
};
sl@0
   875
sl@0
   876
//////////////////////////////////
sl@0
   877
template <typename T, typename TupleT,
sl@0
   878
    typename A, typename B>
sl@0
   879
struct composite2_result<construct_l<T>, TupleT, A, B> {
sl@0
   880
sl@0
   881
    typedef T type;
sl@0
   882
};
sl@0
   883
sl@0
   884
//////////////////////////////////
sl@0
   885
template <typename T, typename TupleT,
sl@0
   886
    typename A, typename B, typename C>
sl@0
   887
struct composite3_result<construct_l<T>, TupleT, A, B, C> {
sl@0
   888
sl@0
   889
    typedef T type;
sl@0
   890
};
sl@0
   891
sl@0
   892
#if PHOENIX_LIMIT > 3
sl@0
   893
//////////////////////////////////
sl@0
   894
template <typename T, typename TupleT,
sl@0
   895
    typename A, typename B, typename C, typename D>
sl@0
   896
struct composite4_result<construct_l<T>, TupleT,
sl@0
   897
    A, B, C, D> {
sl@0
   898
sl@0
   899
    typedef T type;
sl@0
   900
};
sl@0
   901
sl@0
   902
//////////////////////////////////
sl@0
   903
template <typename T, typename TupleT,
sl@0
   904
    typename A, typename B, typename C, typename D, typename E>
sl@0
   905
struct composite5_result<construct_l<T>, TupleT,
sl@0
   906
    A, B, C, D, E> {
sl@0
   907
sl@0
   908
    typedef T type;
sl@0
   909
};
sl@0
   910
sl@0
   911
//////////////////////////////////
sl@0
   912
template <typename T, typename TupleT,
sl@0
   913
    typename A, typename B, typename C, typename D, typename E,
sl@0
   914
    typename F>
sl@0
   915
struct composite6_result<construct_l<T>, TupleT,
sl@0
   916
    A, B, C, D, E, F> {
sl@0
   917
sl@0
   918
    typedef T type;
sl@0
   919
};
sl@0
   920
sl@0
   921
#if PHOENIX_LIMIT > 6
sl@0
   922
//////////////////////////////////
sl@0
   923
template <typename T, typename TupleT,
sl@0
   924
    typename A, typename B, typename C, typename D, typename E,
sl@0
   925
    typename F, typename G>
sl@0
   926
struct composite7_result<construct_l<T>, TupleT,
sl@0
   927
    A, B, C, D, E, F, G> {
sl@0
   928
sl@0
   929
    typedef T type;
sl@0
   930
};
sl@0
   931
sl@0
   932
//////////////////////////////////
sl@0
   933
template <typename T, typename TupleT,
sl@0
   934
    typename A, typename B, typename C, typename D, typename E,
sl@0
   935
    typename F, typename G, typename H>
sl@0
   936
struct composite8_result<construct_l<T>, TupleT,
sl@0
   937
    A, B, C, D, E, F, G, H> {
sl@0
   938
sl@0
   939
    typedef T type;
sl@0
   940
};
sl@0
   941
sl@0
   942
//////////////////////////////////
sl@0
   943
template <typename T, typename TupleT,
sl@0
   944
    typename A, typename B, typename C, typename D, typename E,
sl@0
   945
    typename F, typename G, typename H, typename I>
sl@0
   946
struct composite9_result<construct_l<T>, TupleT,
sl@0
   947
    A, B, C, D, E, F, G, H, I> {
sl@0
   948
sl@0
   949
    typedef T type;
sl@0
   950
};
sl@0
   951
sl@0
   952
#if PHOENIX_LIMIT > 9
sl@0
   953
//////////////////////////////////
sl@0
   954
template <typename T, typename TupleT,
sl@0
   955
    typename A, typename B, typename C, typename D, typename E,
sl@0
   956
    typename F, typename G, typename H, typename I, typename J>
sl@0
   957
struct composite10_result<construct_l<T>, TupleT,
sl@0
   958
    A, B, C, D, E, F, G, H, I, J> {
sl@0
   959
sl@0
   960
    typedef T type;
sl@0
   961
};
sl@0
   962
sl@0
   963
//////////////////////////////////
sl@0
   964
template <typename T, typename TupleT,
sl@0
   965
    typename A, typename B, typename C, typename D, typename E,
sl@0
   966
    typename F, typename G, typename H, typename I, typename J,
sl@0
   967
    typename K>
sl@0
   968
struct composite11_result<construct_l<T>, TupleT,
sl@0
   969
    A, B, C, D, E, F, G, H, I, J, K> {
sl@0
   970
sl@0
   971
    typedef T type;
sl@0
   972
};
sl@0
   973
sl@0
   974
//////////////////////////////////
sl@0
   975
template <typename T, typename TupleT,
sl@0
   976
    typename A, typename B, typename C, typename D, typename E,
sl@0
   977
    typename F, typename G, typename H, typename I, typename J,
sl@0
   978
    typename K, typename L>
sl@0
   979
struct composite12_result<construct_l<T>, TupleT,
sl@0
   980
    A, B, C, D, E, F, G, H, I, J, K, L> {
sl@0
   981
sl@0
   982
    typedef T type;
sl@0
   983
};
sl@0
   984
sl@0
   985
#if PHOENIX_LIMIT > 12
sl@0
   986
//////////////////////////////////
sl@0
   987
template <typename T, typename TupleT,
sl@0
   988
    typename A, typename B, typename C, typename D, typename E,
sl@0
   989
    typename F, typename G, typename H, typename I, typename J,
sl@0
   990
    typename K, typename L, typename M>
sl@0
   991
struct composite13_result<construct_l<T>, TupleT,
sl@0
   992
    A, B, C, D, E, F, G, H, I, J, K, L, M> {
sl@0
   993
sl@0
   994
    typedef T type;
sl@0
   995
};
sl@0
   996
sl@0
   997
//////////////////////////////////
sl@0
   998
template <typename T, typename TupleT,
sl@0
   999
    typename A, typename B, typename C, typename D, typename E,
sl@0
  1000
    typename F, typename G, typename H, typename I, typename J,
sl@0
  1001
    typename K, typename L, typename M, typename N>
sl@0
  1002
struct composite14_result<construct_l<T>, TupleT,
sl@0
  1003
    A, B, C, D, E, F, G, H, I, J, K, L, M, N> {
sl@0
  1004
sl@0
  1005
    typedef T type;
sl@0
  1006
};
sl@0
  1007
sl@0
  1008
//////////////////////////////////
sl@0
  1009
template <typename T, typename TupleT,
sl@0
  1010
    typename A, typename B, typename C, typename D, typename E,
sl@0
  1011
    typename F, typename G, typename H, typename I, typename J,
sl@0
  1012
    typename K, typename L, typename M, typename N, typename O>
sl@0
  1013
struct composite15_result<construct_l<T>, TupleT,
sl@0
  1014
    A, B, C, D, E, F, G, H, I, J, K, L, M, N, O> {
sl@0
  1015
sl@0
  1016
    typedef T type;
sl@0
  1017
};
sl@0
  1018
sl@0
  1019
#endif
sl@0
  1020
#endif
sl@0
  1021
#endif
sl@0
  1022
#endif
sl@0
  1023
#endif
sl@0
  1024
sl@0
  1025
//////////////////////////////////
sl@0
  1026
template <typename T>
sl@0
  1027
inline typename impl::make_composite<construct_l_0<T> >::type
sl@0
  1028
construct_()
sl@0
  1029
{
sl@0
  1030
    typedef impl::make_composite<construct_l_0<T> > make_composite_t;
sl@0
  1031
    typedef typename make_composite_t::type type_t;
sl@0
  1032
    typedef typename make_composite_t::composite_type composite_type_t;
sl@0
  1033
    
sl@0
  1034
    return type_t(composite_type_t(construct_l_0<T>()));
sl@0
  1035
}
sl@0
  1036
sl@0
  1037
//////////////////////////////////
sl@0
  1038
template <typename T, typename A>
sl@0
  1039
inline typename impl::make_composite<construct_1<T>, A>::type
sl@0
  1040
construct_(A const& a)
sl@0
  1041
{
sl@0
  1042
    typedef impl::make_composite<construct_1<T>, A> make_composite_t;
sl@0
  1043
    typedef typename make_composite_t::type type_t;
sl@0
  1044
    typedef typename make_composite_t::composite_type composite_type_t;
sl@0
  1045
sl@0
  1046
    return type_t(composite_type_t(construct_1<T>(), 
sl@0
  1047
        as_actor<A>::convert(a)
sl@0
  1048
    ));
sl@0
  1049
}
sl@0
  1050
sl@0
  1051
//////////////////////////////////
sl@0
  1052
template <typename T, typename A, typename B>
sl@0
  1053
inline typename impl::make_composite<construct_2<T>, A, B>::type
sl@0
  1054
construct_(A const& a, B const& b)
sl@0
  1055
{
sl@0
  1056
    typedef impl::make_composite<construct_2<T>, A, B> make_composite_t;
sl@0
  1057
    typedef typename make_composite_t::type type_t;
sl@0
  1058
    typedef typename make_composite_t::composite_type composite_type_t;
sl@0
  1059
sl@0
  1060
    return type_t(composite_type_t(construct_2<T>(), 
sl@0
  1061
        as_actor<A>::convert(a), 
sl@0
  1062
        as_actor<B>::convert(b)
sl@0
  1063
    ));
sl@0
  1064
}
sl@0
  1065
sl@0
  1066
//////////////////////////////////
sl@0
  1067
template <typename T, typename A, typename B, typename C>
sl@0
  1068
inline typename impl::make_composite<construct_3<T>, A, B, C>::type
sl@0
  1069
construct_(A const& a, B const& b, C const& c)
sl@0
  1070
{
sl@0
  1071
    typedef impl::make_composite<construct_3<T>, A, B, C> make_composite_t;
sl@0
  1072
    typedef typename make_composite_t::type type_t;
sl@0
  1073
    typedef typename make_composite_t::composite_type composite_type_t;
sl@0
  1074
sl@0
  1075
    return type_t(composite_type_t(construct_3<T>(), 
sl@0
  1076
        as_actor<A>::convert(a), 
sl@0
  1077
        as_actor<B>::convert(b),
sl@0
  1078
        as_actor<C>::convert(c)
sl@0
  1079
    ));
sl@0
  1080
}
sl@0
  1081
sl@0
  1082
#if PHOENIX_CONSTRUCT_LIMIT > 3
sl@0
  1083
//////////////////////////////////
sl@0
  1084
template <
sl@0
  1085
    typename T, typename A, typename B, typename C, typename D
sl@0
  1086
>
sl@0
  1087
inline typename impl::make_composite<construct_4<T>, A, B, C, D>::type
sl@0
  1088
construct_(
sl@0
  1089
    A const& a, B const& b, C const& c, D const& d)
sl@0
  1090
{
sl@0
  1091
    typedef
sl@0
  1092
        impl::make_composite<construct_4<T>, A, B, C, D>
sl@0
  1093
        make_composite_t;
sl@0
  1094
    typedef typename make_composite_t::type type_t;
sl@0
  1095
    typedef typename make_composite_t::composite_type composite_type_t;
sl@0
  1096
sl@0
  1097
    return type_t(composite_type_t(construct_4<T>(), 
sl@0
  1098
        as_actor<A>::convert(a), 
sl@0
  1099
        as_actor<B>::convert(b),
sl@0
  1100
        as_actor<C>::convert(c),
sl@0
  1101
        as_actor<D>::convert(d)
sl@0
  1102
    ));
sl@0
  1103
}
sl@0
  1104
sl@0
  1105
//////////////////////////////////
sl@0
  1106
template <
sl@0
  1107
    typename T, typename A, typename B, typename C, typename D, typename E
sl@0
  1108
>
sl@0
  1109
inline typename impl::make_composite<construct_5<T>, A, B, C, D, E>::type
sl@0
  1110
construct_(
sl@0
  1111
    A const& a, B const& b, C const& c, D const& d, E const& e)
sl@0
  1112
{
sl@0
  1113
    typedef
sl@0
  1114
        impl::make_composite<construct_5<T>, A, B, C, D, E>
sl@0
  1115
        make_composite_t;
sl@0
  1116
    typedef typename make_composite_t::type type_t;
sl@0
  1117
    typedef typename make_composite_t::composite_type composite_type_t;
sl@0
  1118
sl@0
  1119
    return type_t(composite_type_t(construct_5<T>(), 
sl@0
  1120
        as_actor<A>::convert(a), 
sl@0
  1121
        as_actor<B>::convert(b),
sl@0
  1122
        as_actor<C>::convert(c),
sl@0
  1123
        as_actor<D>::convert(d),
sl@0
  1124
        as_actor<E>::convert(e)
sl@0
  1125
    ));
sl@0
  1126
}
sl@0
  1127
sl@0
  1128
//////////////////////////////////
sl@0
  1129
template <
sl@0
  1130
    typename T, typename A, typename B, typename C, typename D, typename E,
sl@0
  1131
    typename F
sl@0
  1132
>
sl@0
  1133
inline typename impl::make_composite<construct_6<T>, A, B, C, D, E, F>::type
sl@0
  1134
construct_(
sl@0
  1135
    A const& a, B const& b, C const& c, D const& d, E const& e,
sl@0
  1136
    F const& f)
sl@0
  1137
{
sl@0
  1138
    typedef
sl@0
  1139
        impl::make_composite<construct_6<T>, A, B, C, D, E, F>
sl@0
  1140
        make_composite_t;
sl@0
  1141
    typedef typename make_composite_t::type type_t;
sl@0
  1142
    typedef typename make_composite_t::composite_type composite_type_t;
sl@0
  1143
sl@0
  1144
    return type_t(composite_type_t(construct_6<T>(), 
sl@0
  1145
        as_actor<A>::convert(a), 
sl@0
  1146
        as_actor<B>::convert(b),
sl@0
  1147
        as_actor<C>::convert(c),
sl@0
  1148
        as_actor<D>::convert(d),
sl@0
  1149
        as_actor<E>::convert(e),
sl@0
  1150
        as_actor<F>::convert(f)
sl@0
  1151
    ));
sl@0
  1152
}
sl@0
  1153
sl@0
  1154
#if PHOENIX_CONSTRUCT_LIMIT > 6
sl@0
  1155
//////////////////////////////////
sl@0
  1156
template <
sl@0
  1157
    typename T, typename A, typename B, typename C, typename D, typename E,
sl@0
  1158
    typename F, typename G
sl@0
  1159
>
sl@0
  1160
inline typename impl::make_composite<construct_7<T>, A, B, C, D, E, F, G>::type
sl@0
  1161
construct_(
sl@0
  1162
    A const& a, B const& b, C const& c, D const& d, E const& e,
sl@0
  1163
    F const& f, G const& g)
sl@0
  1164
{
sl@0
  1165
    typedef
sl@0
  1166
        impl::make_composite<construct_7<T>, A, B, C, D, E, F, G>
sl@0
  1167
        make_composite_t;
sl@0
  1168
    typedef typename make_composite_t::type type_t;
sl@0
  1169
    typedef typename make_composite_t::composite_type composite_type_t;
sl@0
  1170
sl@0
  1171
    return type_t(composite_type_t(construct_7<T>(), 
sl@0
  1172
        as_actor<A>::convert(a), 
sl@0
  1173
        as_actor<B>::convert(b),
sl@0
  1174
        as_actor<C>::convert(c),
sl@0
  1175
        as_actor<D>::convert(d),
sl@0
  1176
        as_actor<E>::convert(e),
sl@0
  1177
        as_actor<F>::convert(f),
sl@0
  1178
        as_actor<G>::convert(g)
sl@0
  1179
    ));
sl@0
  1180
}
sl@0
  1181
sl@0
  1182
//////////////////////////////////
sl@0
  1183
template <
sl@0
  1184
    typename T, typename A, typename B, typename C, typename D, typename E,
sl@0
  1185
    typename F, typename G, typename H
sl@0
  1186
>
sl@0
  1187
inline typename impl::make_composite<construct_8<T>, A, B, C, D, E, F, G, H>::type
sl@0
  1188
construct_(
sl@0
  1189
    A const& a, B const& b, C const& c, D const& d, E const& e,
sl@0
  1190
    F const& f, G const& g, H const& h)
sl@0
  1191
{
sl@0
  1192
    typedef
sl@0
  1193
        impl::make_composite<construct_8<T>, A, B, C, D, E, F, G, H>
sl@0
  1194
        make_composite_t;
sl@0
  1195
    typedef typename make_composite_t::type type_t;
sl@0
  1196
    typedef typename make_composite_t::composite_type composite_type_t;
sl@0
  1197
sl@0
  1198
    return type_t(composite_type_t(construct_8<T>(), 
sl@0
  1199
        as_actor<A>::convert(a), 
sl@0
  1200
        as_actor<B>::convert(b),
sl@0
  1201
        as_actor<C>::convert(c),
sl@0
  1202
        as_actor<D>::convert(d),
sl@0
  1203
        as_actor<E>::convert(e),
sl@0
  1204
        as_actor<F>::convert(f),
sl@0
  1205
        as_actor<G>::convert(g),
sl@0
  1206
        as_actor<H>::convert(h)
sl@0
  1207
    ));
sl@0
  1208
}
sl@0
  1209
sl@0
  1210
//////////////////////////////////
sl@0
  1211
template <
sl@0
  1212
    typename T, typename A, typename B, typename C, typename D, typename E,
sl@0
  1213
    typename F, typename G, typename H, typename I
sl@0
  1214
>
sl@0
  1215
inline typename impl::make_composite<construct_9<T>, A, B, C, D, E, F, G, H, I>::type
sl@0
  1216
construct_(
sl@0
  1217
    A const& a, B const& b, C const& c, D const& d, E const& e,
sl@0
  1218
    F const& f, G const& g, H const& h, I const& i)
sl@0
  1219
{
sl@0
  1220
    typedef
sl@0
  1221
        impl::make_composite<construct_9<T>, A, B, C, D, E, F, G, H, I>
sl@0
  1222
        make_composite_t;
sl@0
  1223
    typedef typename make_composite_t::type type_t;
sl@0
  1224
    typedef typename make_composite_t::composite_type composite_type_t;
sl@0
  1225
sl@0
  1226
    return type_t(composite_type_t(construct_9<T>(), 
sl@0
  1227
        as_actor<A>::convert(a), 
sl@0
  1228
        as_actor<B>::convert(b),
sl@0
  1229
        as_actor<C>::convert(c),
sl@0
  1230
        as_actor<D>::convert(d),
sl@0
  1231
        as_actor<E>::convert(e),
sl@0
  1232
        as_actor<F>::convert(f),
sl@0
  1233
        as_actor<G>::convert(g),
sl@0
  1234
        as_actor<H>::convert(h),
sl@0
  1235
        as_actor<I>::convert(i)
sl@0
  1236
    ));
sl@0
  1237
}
sl@0
  1238
sl@0
  1239
#if PHOENIX_CONSTRUCT_LIMIT > 9
sl@0
  1240
//////////////////////////////////
sl@0
  1241
template <
sl@0
  1242
    typename T, typename A, typename B, typename C, typename D, typename E,
sl@0
  1243
    typename F, typename G, typename H, typename I, typename J
sl@0
  1244
>
sl@0
  1245
inline typename impl::make_composite<
sl@0
  1246
    construct_10<T>, A, B, C, D, E, F, G, H, I, J>::type
sl@0
  1247
construct_(
sl@0
  1248
    A const& a, B const& b, C const& c, D const& d, E const& e,
sl@0
  1249
    F const& f, G const& g, H const& h, I const& i, J const& j)
sl@0
  1250
{
sl@0
  1251
    typedef
sl@0
  1252
        impl::make_composite<
sl@0
  1253
            construct_10<T>, A, B, C, D, E, F, G, H, I, J
sl@0
  1254
        >
sl@0
  1255
        make_composite_t;
sl@0
  1256
    typedef typename make_composite_t::type type_t;
sl@0
  1257
    typedef typename make_composite_t::composite_type composite_type_t;
sl@0
  1258
sl@0
  1259
    return type_t(composite_type_t(construct_10<T>(), 
sl@0
  1260
        as_actor<A>::convert(a), 
sl@0
  1261
        as_actor<B>::convert(b),
sl@0
  1262
        as_actor<C>::convert(c),
sl@0
  1263
        as_actor<D>::convert(d),
sl@0
  1264
        as_actor<E>::convert(e),
sl@0
  1265
        as_actor<F>::convert(f),
sl@0
  1266
        as_actor<G>::convert(g),
sl@0
  1267
        as_actor<H>::convert(h),
sl@0
  1268
        as_actor<I>::convert(i),
sl@0
  1269
        as_actor<J>::convert(j)
sl@0
  1270
    ));
sl@0
  1271
}
sl@0
  1272
sl@0
  1273
//////////////////////////////////
sl@0
  1274
template <
sl@0
  1275
    typename T, typename A, typename B, typename C, typename D, typename E,
sl@0
  1276
    typename F, typename G, typename H, typename I, typename J, typename K
sl@0
  1277
>
sl@0
  1278
inline typename impl::make_composite<
sl@0
  1279
    construct_11<T>, A, B, C, D, E, F, G, H, I, J, K>::type
sl@0
  1280
construct_(
sl@0
  1281
    A const& a, B const& b, C const& c, D const& d, E const& e,
sl@0
  1282
    F const& f, G const& g, H const& h, I const& i, J const& j,
sl@0
  1283
    K const& k)
sl@0
  1284
{
sl@0
  1285
    typedef
sl@0
  1286
        impl::make_composite<
sl@0
  1287
            construct_11<T>, A, B, C, D, E, F, G, H, I, J, K
sl@0
  1288
        >
sl@0
  1289
        make_composite_t;
sl@0
  1290
    typedef typename make_composite_t::type type_t;
sl@0
  1291
    typedef typename make_composite_t::composite_type composite_type_t;
sl@0
  1292
sl@0
  1293
    return type_t(composite_type_t(construct_11<T>(), 
sl@0
  1294
        as_actor<A>::convert(a), 
sl@0
  1295
        as_actor<B>::convert(b),
sl@0
  1296
        as_actor<C>::convert(c),
sl@0
  1297
        as_actor<D>::convert(d),
sl@0
  1298
        as_actor<E>::convert(e),
sl@0
  1299
        as_actor<F>::convert(f),
sl@0
  1300
        as_actor<G>::convert(g),
sl@0
  1301
        as_actor<H>::convert(h),
sl@0
  1302
        as_actor<I>::convert(i),
sl@0
  1303
        as_actor<J>::convert(j),
sl@0
  1304
        as_actor<K>::convert(k)
sl@0
  1305
    ));
sl@0
  1306
}
sl@0
  1307
sl@0
  1308
//////////////////////////////////
sl@0
  1309
template <
sl@0
  1310
    typename T, typename A, typename B, typename C, typename D, typename E,
sl@0
  1311
    typename F, typename G, typename H, typename I, typename J, typename K,
sl@0
  1312
    typename L
sl@0
  1313
>
sl@0
  1314
inline typename impl::make_composite<
sl@0
  1315
    construct_12<T>, A, B, C, D, E, F, G, H, I, J, K, L>::type
sl@0
  1316
construct_(
sl@0
  1317
    A const& a, B const& b, C const& c, D const& d, E const& e,
sl@0
  1318
    F const& f, G const& g, H const& h, I const& i, J const& j,
sl@0
  1319
    K const& k, L const& l)
sl@0
  1320
{
sl@0
  1321
    typedef
sl@0
  1322
        impl::make_composite<
sl@0
  1323
            construct_12<T>, A, B, C, D, E, F, G, H, I, J, K, L
sl@0
  1324
        >
sl@0
  1325
        make_composite_t;
sl@0
  1326
    typedef typename make_composite_t::type type_t;
sl@0
  1327
    typedef typename make_composite_t::composite_type composite_type_t;
sl@0
  1328
sl@0
  1329
    return type_t(composite_type_t(construct_12<T>(), 
sl@0
  1330
        as_actor<A>::convert(a), 
sl@0
  1331
        as_actor<B>::convert(b),
sl@0
  1332
        as_actor<C>::convert(c),
sl@0
  1333
        as_actor<D>::convert(d),
sl@0
  1334
        as_actor<E>::convert(e),
sl@0
  1335
        as_actor<F>::convert(f),
sl@0
  1336
        as_actor<G>::convert(g),
sl@0
  1337
        as_actor<H>::convert(h),
sl@0
  1338
        as_actor<I>::convert(i),
sl@0
  1339
        as_actor<J>::convert(j),
sl@0
  1340
        as_actor<K>::convert(k),
sl@0
  1341
        as_actor<L>::convert(l)
sl@0
  1342
    ));
sl@0
  1343
}
sl@0
  1344
sl@0
  1345
#if PHOENIX_CONSTRUCT_LIMIT > 12
sl@0
  1346
//////////////////////////////////
sl@0
  1347
template <
sl@0
  1348
    typename T, typename A, typename B, typename C, typename D, typename E,
sl@0
  1349
    typename F, typename G, typename H, typename I, typename J, typename K,
sl@0
  1350
    typename L, typename M
sl@0
  1351
>
sl@0
  1352
inline typename impl::make_composite<
sl@0
  1353
    construct_13<T>, A, B, C, D, E, F, G, H, I, J, K, L, M>::type
sl@0
  1354
construct_(
sl@0
  1355
    A const& a, B const& b, C const& c, D const& d, E const& e,
sl@0
  1356
    F const& f, G const& g, H const& h, I const& i, J const& j,
sl@0
  1357
    K const& k, L const& l, M const& m)
sl@0
  1358
{
sl@0
  1359
    typedef
sl@0
  1360
        impl::make_composite<
sl@0
  1361
            construct_13<T>, A, B, C, D, E, F, G, H, I, J, K, L, M
sl@0
  1362
        >
sl@0
  1363
        make_composite_t;
sl@0
  1364
    typedef typename make_composite_t::type type_t;
sl@0
  1365
    typedef typename make_composite_t::composite_type composite_type_t;
sl@0
  1366
sl@0
  1367
    return type_t(composite_type_t(construct_13<T>(), 
sl@0
  1368
        as_actor<A>::convert(a), 
sl@0
  1369
        as_actor<B>::convert(b),
sl@0
  1370
        as_actor<C>::convert(c),
sl@0
  1371
        as_actor<D>::convert(d),
sl@0
  1372
        as_actor<E>::convert(e),
sl@0
  1373
        as_actor<F>::convert(f),
sl@0
  1374
        as_actor<G>::convert(g),
sl@0
  1375
        as_actor<H>::convert(h),
sl@0
  1376
        as_actor<I>::convert(i),
sl@0
  1377
        as_actor<J>::convert(j),
sl@0
  1378
        as_actor<K>::convert(k),
sl@0
  1379
        as_actor<L>::convert(l),
sl@0
  1380
        as_actor<M>::convert(m)
sl@0
  1381
    ));
sl@0
  1382
}
sl@0
  1383
sl@0
  1384
//////////////////////////////////
sl@0
  1385
template <
sl@0
  1386
    typename T, typename A, typename B, typename C, typename D, typename E,
sl@0
  1387
    typename F, typename G, typename H, typename I, typename J, typename K,
sl@0
  1388
    typename L, typename M, typename N
sl@0
  1389
>
sl@0
  1390
inline typename impl::make_composite<
sl@0
  1391
    construct_14<T>, A, B, C, D, E, F, G, H, I, J, K, L, M>::type
sl@0
  1392
construct_(
sl@0
  1393
    A const& a, B const& b, C const& c, D const& d, E const& e,
sl@0
  1394
    F const& f, G const& g, H const& h, I const& i, J const& j,
sl@0
  1395
    K const& k, L const& l, M const& m, N const& n)
sl@0
  1396
{
sl@0
  1397
    typedef
sl@0
  1398
        impl::make_composite<
sl@0
  1399
            construct_14<T>, A, B, C, D, E, F, G, H, I, J, K, L, M, N
sl@0
  1400
        >
sl@0
  1401
        make_composite_t;
sl@0
  1402
    typedef typename make_composite_t::type type_t;
sl@0
  1403
    typedef typename make_composite_t::composite_type composite_type_t;
sl@0
  1404
sl@0
  1405
    return type_t(composite_type_t(construct_14<T>(), 
sl@0
  1406
        as_actor<A>::convert(a), 
sl@0
  1407
        as_actor<B>::convert(b),
sl@0
  1408
        as_actor<C>::convert(c),
sl@0
  1409
        as_actor<D>::convert(d),
sl@0
  1410
        as_actor<E>::convert(e),
sl@0
  1411
        as_actor<F>::convert(f),
sl@0
  1412
        as_actor<G>::convert(g),
sl@0
  1413
        as_actor<H>::convert(h),
sl@0
  1414
        as_actor<I>::convert(i),
sl@0
  1415
        as_actor<J>::convert(j),
sl@0
  1416
        as_actor<K>::convert(k),
sl@0
  1417
        as_actor<L>::convert(l),
sl@0
  1418
        as_actor<M>::convert(m),
sl@0
  1419
        as_actor<N>::convert(n)
sl@0
  1420
    ));
sl@0
  1421
}
sl@0
  1422
sl@0
  1423
//////////////////////////////////
sl@0
  1424
template <
sl@0
  1425
    typename T, typename A, typename B, typename C, typename D, typename E,
sl@0
  1426
    typename F, typename G, typename H, typename I, typename J, typename K,
sl@0
  1427
    typename L, typename M, typename N, typename O
sl@0
  1428
>
sl@0
  1429
inline typename impl::make_composite<
sl@0
  1430
    construct_15<T>, A, B, C, D, E, F, G, H, I, J, K, L, M, O>::type
sl@0
  1431
construct_(
sl@0
  1432
    A const& a, B const& b, C const& c, D const& d, E const& e,
sl@0
  1433
    F const& f, G const& g, H const& h, I const& i, J const& j,
sl@0
  1434
    K const& k, L const& l, M const& m, N const& n, O const& o)
sl@0
  1435
{
sl@0
  1436
    typedef
sl@0
  1437
        impl::make_composite<
sl@0
  1438
            construct_15<T>, A, B, C, D, E, F, G, H, I, J, K, L, M, N, O
sl@0
  1439
        >
sl@0
  1440
        make_composite_t;
sl@0
  1441
    typedef typename make_composite_t::type type_t;
sl@0
  1442
    typedef typename make_composite_t::composite_type composite_type_t;
sl@0
  1443
sl@0
  1444
    return type_t(composite_type_t(construct_15<T>(), 
sl@0
  1445
        as_actor<A>::convert(a), 
sl@0
  1446
        as_actor<B>::convert(b),
sl@0
  1447
        as_actor<C>::convert(c),
sl@0
  1448
        as_actor<D>::convert(d),
sl@0
  1449
        as_actor<E>::convert(e),
sl@0
  1450
        as_actor<F>::convert(f),
sl@0
  1451
        as_actor<G>::convert(g),
sl@0
  1452
        as_actor<H>::convert(h),
sl@0
  1453
        as_actor<I>::convert(i),
sl@0
  1454
        as_actor<J>::convert(j),
sl@0
  1455
        as_actor<K>::convert(k),
sl@0
  1456
        as_actor<L>::convert(l),
sl@0
  1457
        as_actor<M>::convert(m),
sl@0
  1458
        as_actor<N>::convert(n),
sl@0
  1459
        as_actor<O>::convert(o)
sl@0
  1460
    ));
sl@0
  1461
}
sl@0
  1462
sl@0
  1463
#endif
sl@0
  1464
#endif
sl@0
  1465
#endif
sl@0
  1466
#endif
sl@0
  1467
sl@0
  1468
///////////////////////////////////////////////////////////////////////////////
sl@0
  1469
}   //  namespace phoenix
sl@0
  1470
sl@0
  1471
#endif // PHOENIX_CASTS_HPP