blob: 33ff1b53709998ff4c1c24008ec7698753b06013 [file] [log] [blame]
Jeff Thompsona28eed82013-08-22 16:21:10 -07001
2// Copyright (C) 2009-2012 Lorenzo Caminiti
3// Distributed under the Boost Software License, Version 1.0
4// (see accompanying file LICENSE_1_0.txt or a copy at
5// http://www.boost.org/LICENSE_1_0.txt)
6// Home at http://www.boost.org/libs/functional/overloaded_function
7
8#ifndef BOOST_FUNCTIONAL_OVERLOADED_FUNCTION_CONFIG_HPP_
9#define BOOST_FUNCTIONAL_OVERLOADED_FUNCTION_CONFIG_HPP_
10
11/** @file
12@brief Change the compile-time configuration of this library.
13*/
14
15/**
16@brief Specify the maximum number of arguments of the functions being
17overloaded.
18
19If this macro is left undefined by the user, it has a default value of 5
20(increasing this number might increase compilation time).
21When specified by the user, this macro must be a non-negative integer number.
22
23@See @RefSect{getting_started, Getting Started},
24@RefClass{ndnboost::overloaded_function}.
25*/
26#ifndef BOOST_FUNCTIONAL_OVERLOADED_FUNCTION_CONFIG_ARITY_MAX
27# define BOOST_FUNCTIONAL_OVERLOADED_FUNCTION_CONFIG_ARITY_MAX 5
28#endif
29
30/**
31@brief Specify the maximum number of functions that can be overloaded.
32
33If this macro is left undefined by the user, it has a default value of 5
34(increasing this number might increase compilation time).
35When defined by the user, this macro must be an integer number greater or
36equal than 2 (because at least two distinct functions need to be specified in
37order to define an overload).
38
39@See @RefSect{getting_started, Getting Started},
40@RefClass{ndnboost::overloaded_function}.
41*/
42#ifndef BOOST_FUNCTIONAL_OVERLOADED_FUNCTION_CONFIG_OVERLOAD_MAX
43# define BOOST_FUNCTIONAL_OVERLOADED_FUNCTION_CONFIG_OVERLOAD_MAX 5
44#endif
45#if BOOST_FUNCTIONAL_OVERLOADED_FUNCTION_CONFIG_OVERLOAD_MAX < 2
46# error "maximum overload macro cannot be less than 2"
47#endif
48
49#endif // #include guard
50