fixes warning in clang-6

This commit is contained in:
Hans Dembinski
2019-10-19 14:02:08 +02:00
parent cda275e884
commit d32f9c5864

View File

@ -996,7 +996,8 @@ namespace std{ using ::type_info; }
// [[nodiscard]]:
//
#ifdef __has_cpp_attribute
#if __has_cpp_attribute(nodiscard)
// clang-6 accepts [[nodiscard]] with -std=c++14, but warns about it -pedantic
#if __has_cpp_attribute(nodiscard) && !(defined(__clang__) && (__cplusplus < 201703L))
# define BOOST_ATTRIBUTE_NODISCARD [[nodiscard]]
#endif
#if __has_cpp_attribute(no_unique_address) && !(defined(__GNUC__) && (__cplusplus < 201100))