diff --git a/include/boost/smart_ptr/bad_weak_ptr.hpp b/include/boost/smart_ptr/bad_weak_ptr.hpp index 3e0a1b7..582fad8 100644 --- a/include/boost/smart_ptr/bad_weak_ptr.hpp +++ b/include/boost/smart_ptr/bad_weak_ptr.hpp @@ -36,6 +36,11 @@ namespace boost # pragma option push -pc #endif +#if defined(__clang__) +# pragma clang diagnostic push +# pragma clang diagnostic ignored "-Wweak-vtables" +#endif + class bad_weak_ptr: public std::exception { public: @@ -46,6 +51,10 @@ public: } }; +#if defined(__clang__) +# pragma clang diagnostic pop +#endif + #if defined(__BORLANDC__) && __BORLANDC__ <= 0x564 # pragma option pop #endif diff --git a/include/boost/smart_ptr/detail/sp_counted_base_clang.hpp b/include/boost/smart_ptr/detail/sp_counted_base_clang.hpp index c66b985..7598495 100644 --- a/include/boost/smart_ptr/detail/sp_counted_base_clang.hpp +++ b/include/boost/smart_ptr/detail/sp_counted_base_clang.hpp @@ -58,6 +58,11 @@ inline boost::int_least32_t atomic_conditional_increment( atomic_int_least32_t * } } +#if defined(__clang__) +# pragma clang diagnostic push +# pragma clang diagnostic ignored "-Wweak-vtables" +#endif + class sp_counted_base { private: @@ -133,6 +138,10 @@ public: } }; +#if defined(__clang__) +# pragma clang diagnostic pop +#endif + } // namespace detail } // namespace boost