1 // Boost.Function library
3 // Copyright Douglas Gregor 2001-2003. Use, modification and
4 // distribution is subject to the Boost Software License, Version
5 // 1.0. (See accompanying file LICENSE_1_0.txt or copy at
6 // http://www.boost.org/LICENSE_1_0.txt)
8 // For more information, see http://www.boost.org/libs/function
10 // William Kempf, Jesse Jones and Karl Nelson were all very helpful in the
11 // design of this library.
13 #ifndef BOOST_FUNCTION_MAX_ARGS
14 # define BOOST_FUNCTION_MAX_ARGS 10
15 #endif // BOOST_FUNCTION_MAX_ARGS
17 #if !defined(BOOST_FUNCTION_MAX_ARGS_DEFINED) || (BOOST_FUNCTION_MAX_ARGS_DEFINED != BOOST_FUNCTION_MAX_ARGS)
19 #if !defined(BOOST_FUNCTION_MAX_ARGS_DEFINED)
20 #define BOOST_FUNCTION_MAX_ARGS_DEFINED 0
23 #include <functional> // unary_function, binary_function
25 #include <boost/preprocessor/iterate.hpp>
26 #include <boost/config/workaround.hpp>
28 // Include the prologue here so that the use of file-level iteration
29 // in anything that may be included by function_template.hpp doesn't break
30 #include <boost/function/detail/prologue.hpp>
32 // Older Visual Age C++ version do not handle the file iteration well
33 #if BOOST_WORKAROUND(__IBMCPP__, >= 500) && BOOST_WORKAROUND(__IBMCPP__, < 800)
34 # if BOOST_FUNCTION_MAX_ARGS >= 0
35 # include <boost/function/function0.hpp>
37 # if BOOST_FUNCTION_MAX_ARGS >= 1
38 # include <boost/function/function1.hpp>
40 # if BOOST_FUNCTION_MAX_ARGS >= 2
41 # include <boost/function/function2.hpp>
43 # if BOOST_FUNCTION_MAX_ARGS >= 3
44 # include <boost/function/function3.hpp>
46 # if BOOST_FUNCTION_MAX_ARGS >= 4
47 # include <boost/function/function4.hpp>
49 # if BOOST_FUNCTION_MAX_ARGS >= 5
50 # include <boost/function/function5.hpp>
52 # if BOOST_FUNCTION_MAX_ARGS >= 6
53 # include <boost/function/function6.hpp>
55 # if BOOST_FUNCTION_MAX_ARGS >= 7
56 # include <boost/function/function7.hpp>
58 # if BOOST_FUNCTION_MAX_ARGS >= 8
59 # include <boost/function/function8.hpp>
61 # if BOOST_FUNCTION_MAX_ARGS >= 9
62 # include <boost/function/function9.hpp>
64 # if BOOST_FUNCTION_MAX_ARGS >= 10
65 # include <boost/function/function10.hpp>
68 // What is the '3' for?
69 # define BOOST_PP_ITERATION_PARAMS_1 (3,(0,BOOST_FUNCTION_MAX_ARGS,<boost/function/detail/function_iterate.hpp>))
70 # include BOOST_PP_ITERATE()
71 # undef BOOST_PP_ITERATION_PARAMS_1
74 #endif // !defined(BOOST_FUNCTION_MAX_ARGS_DEFINED) || (BOOST_FUNCTION_MAX_ARGS_DEFINED != BOOST_FUNCTION_MAX_ARGS)