Skip to content

Commit

Permalink
Remove unnecessary ifs
Browse files Browse the repository at this point in the history
  • Loading branch information
pdimov committed Jan 28, 2024
1 parent 6de542f commit 50ac0b7
Showing 1 changed file with 0 additions and 8 deletions.
8 changes: 0 additions & 8 deletions include/boost/function/function_template.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -129,7 +129,6 @@ namespace boost {
}
};

#if BOOST_FUNCTION_NUM_ARGS > 0
/* Handle invocation of member pointers. */
template<
typename MemberPtr,
Expand Down Expand Up @@ -165,7 +164,6 @@ namespace boost {
boost::mem_fn(*f)(static_cast<T&&>(a)...);
}
};
#endif

template<
typename FunctionPtr,
Expand Down Expand Up @@ -230,7 +228,6 @@ namespace boost {
>::type type;
};

#if BOOST_FUNCTION_NUM_ARGS > 0
/* Retrieve the appropriate invoker for a member pointer. */
template<
typename MemberPtr,
Expand All @@ -252,7 +249,6 @@ namespace boost {
>
>::type type;
};
#endif

/* Given the tag returned by get_function_tag, retrieve the
actual invoker that will be used for the given function
Expand Down Expand Up @@ -299,7 +295,6 @@ namespace boost {
};
};

#if BOOST_FUNCTION_NUM_ARGS > 0
/* Retrieve the invoker for a member pointer. */
template<>
struct get_invoker<member_ptr_tag>
Expand Down Expand Up @@ -332,7 +327,6 @@ namespace boost {
typedef functor_manager<MemberPtr> manager_type;
};
};
#endif

/* Retrieve the invoker for a function object. */
template<>
Expand Down Expand Up @@ -468,7 +462,6 @@ namespace boost {
}

// Member pointers
#if BOOST_FUNCTION_NUM_ARGS > 0
template<typename MemberPtr>
bool assign_to(MemberPtr f, function_buffer& functor, member_ptr_tag) const
{
Expand All @@ -495,7 +488,6 @@ namespace boost {
return false;
}
}
#endif // BOOST_FUNCTION_NUM_ARGS > 0

// Function objects
// Assign to a function object using the small object optimization
Expand Down

0 comments on commit 50ac0b7

Please sign in to comment.