Subject: [Boost-bugs] [Boost C++ Libraries] #2466: function_template.hpp uses exceptions even when BOOST_NO_EXCEPTIONS is defined
From: Boost C++ Libraries (noreply_at_[hidden])
Date: 2008-11-03 14:45:44
#2466: function_template.hpp uses exceptions even when BOOST_NO_EXCEPTIONS is
defined
---------------------------------------------------+------------------------
Reporter: ANDREW CHITTENDEN <andyc_at_[hidden]> | Type: Bugs
Status: new | Milestone: Boost 1.38.0
Component: None | Version: Boost 1.36.0
Severity: Problem | Keywords:
---------------------------------------------------+------------------------
g++ gives this error message:
/home/andyc/work/tiger/1/include/ppc_BOS/boost/function/function_template.hpp:720:
error: exception handling disabled, use -fexceptions to enable
This patch fixes it:
===== boost/function/function_template.hpp 1.1 vs edited =====
--- 1.1/boost/function/function_template.hpp 2008-10-30 16:15:10 +00:00
+++ edited/boost/function/function_template.hpp 2008-11-03 14:41:30 +00:00
@@ -715,12 +715,16 @@
return *this;
this->clear();
+#ifndef BOOST_NO_EXCEPTIONS
try {
this->assign_to_own(f);
} catch (...) {
vtable = 0;
throw;
}
+#else
+ this->assign_to_own(f);
+#endif
return *this;
}
-- Ticket URL: <https://svn.boost.org/trac/boost/ticket/2466> Boost C++ Libraries <http://www.boost.org/> Boost provides free peer-reviewed portable C++ source libraries.
This archive was generated by hypermail 2.1.7 : 2017-02-16 18:49:59 UTC