forked from boostorg/mp11
Use __attribute__((deprecated)) on Clang because of -pedantic
This commit is contained in:
@@ -128,18 +128,8 @@
|
|||||||
#elif BOOST_MP11_WORKAROUND( BOOST_MP11_GCC, < 50000 )
|
#elif BOOST_MP11_WORKAROUND( BOOST_MP11_GCC, < 50000 )
|
||||||
# define BOOST_MP11_DEPRECATED(msg) __attribute__((deprecated(msg)))
|
# define BOOST_MP11_DEPRECATED(msg) __attribute__((deprecated(msg)))
|
||||||
#elif BOOST_MP11_CLANG
|
#elif BOOST_MP11_CLANG
|
||||||
# if defined(__has_cpp_attribute)
|
// -pedantic warns about [[deprecated]] when in C++11 mode
|
||||||
// 3.8 warns about [[deprecated]] when in C++11 mode
|
# define BOOST_MP11_DEPRECATED(msg) __attribute__((deprecated(msg)))
|
||||||
// so we only use it on 3.9 and above, detected via [[fallthrough]]
|
|
||||||
// can't version check because Apple
|
|
||||||
# if __has_cpp_attribute(deprecated) && __has_cpp_attribute(fallthrough)
|
|
||||||
# define BOOST_MP11_DEPRECATED(msg) [[deprecated(msg)]]
|
|
||||||
# else
|
|
||||||
# define BOOST_MP11_DEPRECATED(msg)
|
|
||||||
# endif
|
|
||||||
# else // defined(__has_cpp_attribute)
|
|
||||||
# define BOOST_MP11_DEPRECATED(msg)
|
|
||||||
# endif
|
|
||||||
#else
|
#else
|
||||||
# define BOOST_MP11_DEPRECATED(msg) [[deprecated(msg)]]
|
# define BOOST_MP11_DEPRECATED(msg) [[deprecated(msg)]]
|
||||||
#endif
|
#endif
|
||||||
|
Reference in New Issue
Block a user