Hideaki Tai / msgpack-embedded

Dependents:   hello_message_pack

Embed: (wiki syntax)

« Back to documentation index

Show/hide line numbers is_empty.hpp Source File

is_empty.hpp

00001 # /* **************************************************************************
00002 #  *                                                                          *
00003 #  *     (C) Copyright Edward Diener 2014.
00004 #  *     Distributed under the Boost Software License, Version 1.0. (See
00005 #  *     accompanying file LICENSE_1_0.txt or copy at
00006 #  *     http://www.boost.org/LICENSE_1_0.txt)
00007 #  *                                                                          *
00008 #  ************************************************************************** */
00009 #
00010 # /* See http://www.boost.org for most recent version. */
00011 #
00012 #ifndef MSGPACK_PREPROCESSOR_DETAIL_IS_EMPTY_HPP
00013 #define MSGPACK_PREPROCESSOR_DETAIL_IS_EMPTY_HPP
00014 
00015 #include <msgpack/preprocessor/punctuation/is_begin_parens.hpp>
00016 
00017 #if MSGPACK_PP_VARIADICS_MSVC
00018 
00019 # pragma warning(once:4002)
00020 
00021 #define MSGPACK_PP_DETAIL_IS_EMPTY_IIF_0(t, b) b
00022 #define MSGPACK_PP_DETAIL_IS_EMPTY_IIF_1(t, b) t
00023 
00024 #else
00025 
00026 #define MSGPACK_PP_DETAIL_IS_EMPTY_IIF_0(t, ...) __VA_ARGS__
00027 #define MSGPACK_PP_DETAIL_IS_EMPTY_IIF_1(t, ...) t
00028 
00029 #endif
00030 
00031 #if MSGPACK_PP_VARIADICS_MSVC && _MSC_VER <= 1400
00032 
00033 #define MSGPACK_PP_DETAIL_IS_EMPTY_PROCESS(param) \
00034     MSGPACK_PP_IS_BEGIN_PARENS \
00035         ( \
00036         MSGPACK_PP_DETAIL_IS_EMPTY_NON_FUNCTION_C param () \
00037         ) \
00038 /**/
00039 
00040 #else
00041 
00042 #define MSGPACK_PP_DETAIL_IS_EMPTY_PROCESS(...) \
00043     MSGPACK_PP_IS_BEGIN_PARENS \
00044         ( \
00045         MSGPACK_PP_DETAIL_IS_EMPTY_NON_FUNCTION_C __VA_ARGS__ () \
00046         ) \
00047 /**/
00048 
00049 #endif
00050 
00051 #define MSGPACK_PP_DETAIL_IS_EMPTY_PRIMITIVE_CAT(a, b) a ## b
00052 #define MSGPACK_PP_DETAIL_IS_EMPTY_IIF(bit) MSGPACK_PP_DETAIL_IS_EMPTY_PRIMITIVE_CAT(MSGPACK_PP_DETAIL_IS_EMPTY_IIF_,bit)
00053 #define MSGPACK_PP_DETAIL_IS_EMPTY_NON_FUNCTION_C(...) ()
00054 
00055 #endif /* MSGPACK_PREPROCESSOR_DETAIL_IS_EMPTY_HPP */