mqtt_cpp
config.hpp
Go to the documentation of this file.
1 // Copyright Takatoshi Kondo 2020
2 //
3 // Distributed under the Boost Software License, Version 1.0.
4 // (See accompanying file LICENSE_1_0.txt or copy at
5 // http://www.boost.org/LICENSE_1_0.txt)
6 
7 #if !defined(MQTT_CONFIG_HPP)
8 #define MQTT_CONFIG_HPP
9 
10 #if !defined(MQTT_STD_VARIANT)
11 
12 // Use boost variant
13 
14 // user intentionally defined BOOST_MPL_LIMIT_LIST_SIZE but size is too small
15 // NOTE: if BOOST_MPL_LIMIT_LIST_SIZE is not defined, the value is evaluate as 0.
16 #if defined(BOOST_MPL_CFG_NO_PREPROCESSED_HEADERS) && BOOST_MPL_LIMIT_LIST_SIZE < 40
17 
18 #error BOOST_MPL_LIMIT_LIST_SIZE need to greator or equal to 40
19 
20 #else // defined(BOOST_MPL_CFG_NO_PREPROCESSED_HEADERS) && BOOST_MPL_LIMIT_LIST_SIZE < 40
21 
22 // user doesn't define BOOST_MPL_LIMIT_LIST_SIZE intentionally
23 // but the defult value could be defined
24 
25 #undef BOOST_MPL_LIMIT_LIST_SIZE
26 #define BOOST_MPL_CFG_NO_PREPROCESSED_HEADERS
27 #define BOOST_MPL_LIMIT_LIST_SIZE 40
28 
29 #endif // defined(BOOST_MPL_CFG_NO_PREPROCESSED_HEADERS) && BOOST_MPL_LIMIT_LIST_SIZE < 40
30 
31 
32 #endif // !defined(MQTT_STD_VARIANT)
33 
34 #endif // MQTT_CONFIG_HPP