|
template<std::uintmax_t I> |
using | kblib::uint_smallest = typename first_bigger_than< 1+filg2(I)/CHAR_BIT, unsigned char, unsigned short, unsigned int, unsigned long, unsigned long long, std::uintmax_t >::type |
|
template<std::uintmax_t I> |
using | kblib::int_smallest = typename first_bigger_than< 1+(filg2(I)+1)/CHAR_BIT, signed char, signed short, signed int, signed long, signed long long, std::uintmax_t >::type |
|
template<std::uintmax_t I> |
using | kblib::uint_smallest_t = typename uint_smallest< I >::type |
|
template<std::uintmax_t I> |
using | kblib::int_smallest_t = typename int_smallest< I >::type |
|
|
template<typename T > |
constexpr auto | kblib::in_range (const T &v, detail_simple::simple_range< T > r) |
|
template<typename T > |
constexpr auto | kblib::in_range_i (const T &v, detail_simple::simple_range< T > r) |
|
template<typename F , typename... T> |
auto | kblib::map (F f, T &&... t) noexcept(noexcept(std::tuple{ kblib::apply(f, std::forward< T >(t))...})) -> enable_if_t< not any_void< decltype(kblib::apply(f, std::forward< T >(t)))... >, decltype(std::tuple{kblib::apply(f, std::forward< T >(t))...})> |
|
template<typename F > |
auto | kblib::defer (F f) |
|
template<typename BinaryOperation > |
constexpr auto | kblib::flip () -> auto |
| Transforms a stateless binary operation into one which takes reversed arguments. More...
|
|
template<typename BinaryOperation > |
constexpr auto | kblib::flip (BinaryOperation op) -> auto |
| Transforms a binary operation into one which takes reversed arguments. More...
|
|
template<typename T , std::size_t N> |
constexpr auto | kblib::is_consecutive (const T(&array)[N]) -> enable_if_t< std::is_integral< T >::value, bool > |
|
constexpr auto | kblib::filg2 (const std::bitset< std::numeric_limits< std::uintmax_t >::digits > val) noexcept -> int |
| Floored integer binary logarithm. Returns floor(lb(val)). More...
|
|
template<typename T > |
auto | kblib::safe_auto (T &&in) -> T |
| Safely propagate an xvalue or lvalue without dangling references. More...
|
|
template<typename T > |
auto | kblib::safe_auto (T &in) -> T & |
| Safely propagate an xvalue or lvalue without dangling references. More...
|
|
template<typename LeftContainer , typename RightContainer > |
auto | kblib::arraycat (LeftContainer A, RightContainer &&B) noexcept(noexcept(A.insert(A.end(), B.begin(), B.end())) and std::is_nothrow_move_constructible< LeftContainer >::value) -> LeftContainer |
| Concatenate two dynamic containers together. More...
|
|
template<typename T > |
constexpr auto | kblib::a (const std::initializer_list< T > &a) -> auto |
| Index an array literal without naming its type. More...
|
|
Provides general utilities which do not fit in any more specific header.
- Author
- killerbee
- Date
- 2019-2021
- Copyright
- GNU General Public Licence v3.0
Definition in file simple.h.