Backport
functional.hpp File Reference

This header provides definitions from the C++ header <functional> More...

#include "detail/config.hpp"
#include "type_traits.hpp"
#include "utility.hpp"
#include "detail/invoke.hpp"
#include <functional>
+ Include dependency graph for functional.hpp:
+ This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

struct  bpstd::plus< T >
 
struct  bpstd::plus< void >
 
struct  bpstd::minus< T >
 
struct  bpstd::minus< void >
 
struct  bpstd::multiplies< T >
 
struct  bpstd::multiplies< void >
 
struct  bpstd::divides< T >
 
struct  bpstd::divides< void >
 
struct  bpstd::modulus< T >
 
struct  bpstd::modulus< void >
 
struct  bpstd::negate< T >
 
struct  bpstd::negate< void >
 
struct  bpstd::equal_to< T >
 
struct  bpstd::equal_to< void >
 
struct  bpstd::not_equal_to< T >
 
struct  bpstd::not_equal_to< void >
 
struct  bpstd::greater< T >
 
struct  bpstd::greater< void >
 
struct  bpstd::greater_equal< T >
 
struct  bpstd::greater_equal< void >
 
struct  bpstd::less< T >
 
struct  bpstd::less< void >
 
struct  bpstd::less_equal< T >
 
struct  bpstd::less_equal< void >
 
struct  bpstd::logical_and< T >
 
struct  bpstd::logical_and< void >
 
struct  bpstd::logical_or< T >
 
struct  bpstd::logical_or< void >
 
struct  bpstd::logical_not< T >
 
struct  bpstd::logical_not< void >
 
struct  bpstd::bit_and< T >
 
struct  bpstd::bit_and< void >
 
struct  bpstd::bit_or< T >
 
struct  bpstd::bit_or< void >
 
struct  bpstd::bit_xor< T >
 
struct  bpstd::bit_xor< void >
 
struct  bpstd::bit_not< T >
 
struct  bpstd::bit_not< void >
 

Functions

template<typename Func , typename... Args>
constexpr invoke_result_t< Func, Args... > bpstd::invoke (Func &&function, Args &&... args) noexcept(is_nothrow_invocable< Func, Args... >::value)
 Invoke the Callable object function with the parameters args. More...
 
template<typename Fn >
constexpr detail::not_fn_t< decay_t< Fn > > bpstd::not_fn (Fn &&fn)
 Creates a forwarding call wrapper that returns the negation of the callable object it holds. More...
 

Detailed Description

This header provides definitions from the C++ header <functional>

Definition in file functional.hpp.

Function Documentation

◆ invoke()

template<typename Func , typename... Args>
constexpr invoke_result_t<Func,Args...> bpstd::invoke ( Func &&  function,
Args &&...  args 
)
constexprnoexcept

Invoke the Callable object function with the parameters args.

As by INVOKE(std::forward<F>(f), std::forward<Args>(args)...)

Parameters
functionCallable object to be invoked
argsarguments to pass to function

◆ not_fn()

template<typename Fn >
constexpr detail::not_fn_t<decay_t<Fn> > bpstd::not_fn ( Fn &&  fn)
constexpr

Creates a forwarding call wrapper that returns the negation of the callable object it holds.

Parameters
fnthe object from which the Callable object held by the wrapper is constructed
Returns
the negated object