Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 4 additions & 3 deletions include/boost/leaf/error.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -429,7 +429,7 @@ namespace detail
BOOST_LEAF_CONSTEXPR inline int load_slot( int err_id, E && e ) noexcept(OnError)
{
using T = typename std::decay<E>::type;
static_assert(!std::is_pointer<E>::value, "Error objects of pointer types are not allowed");
static_assert(!std::is_pointer<T>::value, "Error objects of pointer types are not allowed");
static_assert(!std::is_same<T, error_id>::value, "Error objects of type error_id are not allowed");
BOOST_LEAF_ASSERT((err_id&3) == 1);
if( slot<T> * p = tls::read_ptr<slot<T>>() )
Expand All @@ -449,7 +449,7 @@ namespace detail
{
using E = typename function_traits<F>::return_type;
using T = typename std::decay<E>::type;
static_assert(!std::is_pointer<E>::value, "Error objects of pointer types are not allowed");
static_assert(!std::is_pointer<T>::value, "Error objects of pointer types are not allowed");
static_assert(!std::is_same<T, error_id>::value, "Error objects of type error_id are not allowed");
BOOST_LEAF_ASSERT((err_id&3) == 1);
if( slot<T> * p = tls::read_ptr<slot<T>>() )
Expand All @@ -469,7 +469,8 @@ namespace detail
{
static_assert(function_traits<F>::arity == 1, "Lambdas passed to accumulate must take a single e-type argument by reference");
using E = typename std::decay<fn_arg_type<F,0>>::type;
static_assert(!std::is_pointer<E>::value, "Error objects of pointer types are not allowed");
using T = typename std::decay<E>::type;
static_assert(!std::is_pointer<T>::value, "Error objects of pointer types are not allowed");
BOOST_LEAF_ASSERT((err_id&3) == 1);
if( auto sl = tls::read_ptr<slot<E>>() )
{
Expand Down
Loading