diff --git a/include/boost/functional/factory.hpp b/include/boost/functional/factory.hpp index 3a7ee6d..92f67d9 100644 --- a/include/boost/functional/factory.hpp +++ b/include/boost/functional/factory.hpp @@ -189,13 +189,10 @@ namespace boost try { #if defined(BOOST_NO_CXX11_ALLOCATOR) - return make_pointer( - new(memory) value_type(BOOST_PP_ENUM_PARAMS(N,a)), - boost::non_type() ); + new(memory) value_type(BOOST_PP_ENUM_PARAMS(N,a)); #else allocator_traits::construct(this->get_allocator(), memory BOOST_PP_ENUM_TRAILING_PARAMS(N,a)); - return make_pointer(memory, boost::non_type()); #endif } catch (...) { @@ -206,6 +203,8 @@ namespace boost #endif throw; } + + return make_pointer(memory, boost::non_type()); } # endif # undef N