diff -Naur .build/boost_1_53_0/boost/variant/get.hpp .build/boost_1_53_0_patched/boost/variant/get.hpp --- .build/boost_1_53_0/boost/variant/get.hpp 2005-08-25 18:27:28.000000000 +0200 +++ .build/boost_1_53_0_patched/boost/variant/get.hpp 2013-06-19 11:07:28.119891064 +0200 @@ -17,6 +17,7 @@ #include "boost/config.hpp" #include "boost/detail/workaround.hpp" +#include "boost/throw_exception.hpp" #include "boost/utility/addressof.hpp" #include "boost/variant/variant_fwd.hpp" @@ -177,7 +178,7 @@ U_ptr result = get(&operand); if (!result) - throw bad_get(); + throw_exception(bad_get()); return *result; } @@ -193,7 +194,7 @@ U_ptr result = get(&operand); if (!result) - throw bad_get(); + throw_exception(bad_get()); return *result; } diff -Naur .build/boost_1_53_0/boost/variant/variant.hpp .build/boost_1_53_0_patched/boost/variant/variant.hpp --- .build/boost_1_53_0/boost/variant/variant.hpp 2012-12-08 16:44:16.000000000 +0100 +++ .build/boost_1_53_0_patched/boost/variant/variant.hpp 2013-06-19 11:12:26.521370749 +0200 @@ -38,6 +38,7 @@ #include "boost/variant/detail/has_nothrow_move.hpp" #include "boost/variant/detail/move.hpp" +#include "boost/detail/no_exceptions_support.hpp" #include "boost/detail/reference_content.hpp" #include "boost/aligned_storage.hpp" #include "boost/blank.hpp" @@ -770,12 +771,12 @@ // ...destroy lhs content... lhs_content.~LhsT(); // nothrow - try + BOOST_TRY { // ...and attempt to copy rhs content into lhs storage: copy_rhs_content_(lhs_.storage_.address(), rhs_content_); } - catch (...) + BOOST_CATCH (...) { // In case of failure, restore backup content to lhs storage... new(lhs_.storage_.address()) @@ -784,8 +785,9 @@ ); // nothrow // ...and rethrow: - throw; + BOOST_RETHROW } + BOOST_CATCH_END // In case of success, indicate new content type: lhs_.indicate_which(rhs_which_); // nothrow @@ -803,12 +805,12 @@ // ...destroy lhs content... lhs_content.~LhsT(); // nothrow - try + BOOST_TRY { // ...and attempt to copy rhs content into lhs storage: copy_rhs_content_(lhs_.storage_.address(), rhs_content_); } - catch (...) + BOOST_CATCH (...) { // In case of failure, copy backup pointer to lhs storage... new(lhs_.storage_.address()) @@ -818,8 +820,9 @@ lhs_.indicate_backup_which( lhs_.which() ); // nothrow // ...and rethrow: - throw; + BOOST_RETHROW } + BOOST_CATCH_END // In case of success, indicate new content type... lhs_.indicate_which(rhs_which_); // nothrow @@ -1860,13 +1863,13 @@ // Destroy lhs's content... lhs_.destroy_content(); // nothrow - try + BOOST_TRY { // ...and attempt to copy rhs's content into lhs's storage: new(lhs_.storage_.address()) RhsT( rhs_content ); } - catch (...) + BOOST_CATCH (...) { // In case of failure, default-construct fallback type in lhs's storage... new (lhs_.storage_.address()) @@ -1878,8 +1881,9 @@ ); // nothrow // ...and rethrow: - throw; + BOOST_RETHROW } + BOOST_CATCH_END // In the event of success, indicate new content type: lhs_.indicate_which(rhs_which_); // nothrow @@ -2004,13 +2008,13 @@ // Destroy lhs's content... lhs_.destroy_content(); // nothrow - try + BOOST_TRY { // ...and attempt to copy rhs's content into lhs's storage: new(lhs_.storage_.address()) RhsT( detail::variant::move(rhs_content) ); } - catch (...) + BOOST_CATCH (...) { // In case of failure, default-construct fallback type in lhs's storage... new (lhs_.storage_.address()) @@ -2022,8 +2026,9 @@ ); // nothrow // ...and rethrow: - throw; + BOOST_RETHROW } + BOOST_CATCH_END // In the event of success, indicate new content type: lhs_.indicate_which(rhs_which_); // nothrow diff -Naur .build/boost_1_53_0/boost/variant/visitor_ptr.hpp .build/boost_1_53_0_patched/boost/variant/visitor_ptr.hpp --- .build/boost_1_53_0/boost/variant/visitor_ptr.hpp 2004-09-02 17:41:37.000000000 +0200 +++ .build/boost_1_53_0_patched/boost/variant/visitor_ptr.hpp 2013-06-19 11:06:48.963696888 +0200 @@ -18,6 +18,7 @@ #include "boost/mpl/eval_if.hpp" #include "boost/mpl/identity.hpp" +#include "boost/throw_exception.hpp" #include "boost/type_traits/add_reference.hpp" #include "boost/type_traits/is_reference.hpp" #include "boost/type_traits/is_void.hpp" @@ -64,7 +65,7 @@ template result_type operator()(const U&) const { - throw bad_visit(); + throw_exception(bad_visit()); } #if !defined(BOOST_NO_VOID_RETURNS)