forked from boostorg/system
Merge pull request #49 from Thomas-Barbier-1A/cpp7_redundant_redeclar_constexpr
Fix c++17 warning redundant redeclaration of 'constexpr' static data
This commit is contained in:
@@ -335,8 +335,11 @@ template<class T> struct BOOST_SYMBOL_VISIBLE cat_holder
|
|||||||
static constexpr generic_error_category generic_category_instance{};
|
static constexpr generic_error_category generic_category_instance{};
|
||||||
};
|
};
|
||||||
|
|
||||||
|
// Before C++17 it was mandatory to redeclare all static constexpr
|
||||||
|
#if defined(BOOST_NO_CXX17_INLINE_VARIABLES)
|
||||||
template<class T> constexpr system_error_category cat_holder<T>::system_category_instance;
|
template<class T> constexpr system_error_category cat_holder<T>::system_category_instance;
|
||||||
template<class T> constexpr generic_error_category cat_holder<T>::generic_category_instance;
|
template<class T> constexpr generic_error_category cat_holder<T>::generic_category_instance;
|
||||||
|
#endif
|
||||||
|
|
||||||
} // namespace detail
|
} // namespace detail
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user