Back to home page

EIC code displayed by LXR

 
 

    


File indexing completed on 2025-01-18 09:29:46

0001 //  static_assert.hpp  --------------------------------------------------------------//
0002 
0003 //  Copyright 2009-2010 Vicente J. Botet Escriba
0004 
0005 //  Distributed under the Boost Software License, Version 1.0.
0006 //  See http://www.boost.org/LICENSE_1_0.txt
0007 
0008 
0009 #ifndef BOOST_CHRONO_DETAIL_STATIC_ASSERT_HPP
0010 #define BOOST_CHRONO_DETAIL_STATIC_ASSERT_HPP
0011 
0012 #include <boost/chrono/config.hpp>
0013 
0014 #ifndef BOOST_NO_CXX11_STATIC_ASSERT
0015 #define BOOST_CHRONO_STATIC_ASSERT(CND, MSG, TYPES) static_assert(CND,MSG)
0016 #elif defined(BOOST_CHRONO_USES_STATIC_ASSERT)
0017 #include <boost/static_assert.hpp>
0018 #define BOOST_CHRONO_STATIC_ASSERT(CND, MSG, TYPES) BOOST_STATIC_ASSERT(CND)
0019 #elif defined(BOOST_CHRONO_USES_MPL_ASSERT)
0020 #include <boost/mpl/assert.hpp>
0021 #include <boost/mpl/bool.hpp>
0022 #define BOOST_CHRONO_STATIC_ASSERT(CND, MSG, TYPES)                                 \
0023     BOOST_MPL_ASSERT_MSG(boost::mpl::bool_< (CND) >::type::value, MSG, TYPES)
0024 #else
0025 //~ #elif defined(BOOST_CHRONO_USES_ARRAY_ASSERT)
0026 #define BOOST_CHRONO_STATIC_ASSERT(CND, MSG, TYPES) static char BOOST_JOIN(boost_chrono_test_,__LINE__)[(CND)?1:-1]
0027 //~ #define BOOST_CHRONO_STATIC_ASSERT(CND, MSG, TYPES)
0028 #endif
0029 
0030 #endif // BOOST_CHRONO_DETAIL_STATIC_ASSERT_HPP