kumi v3.1.0
Exquisite Epidote
 
Loading...
Searching...
No Matches
Tuple Types and Functions

Definition for kumi::tuple class and functions. More...

Classes

class  kumi::tuple< Ts >
 Fixed-size collection of heterogeneous values. More...
 

Friends

template<typename CharT , typename Traits >
std::basic_ostream< CharT, Traits > & operator<< (std::basic_ostream< CharT, Traits > &os, tuple const &t) noexcept
 Inserts a kumi::tuple in an output stream.
 

Comparison operators

template<typename... Us>
requires ( equality_comparable<tuple,tuple<Us...>> )
constexpr auto operator== (tuple const &self, tuple< Us... > const &other) noexcept
 Compares a tuple with an other for equality.
 
template<typename... Us>
requires (sizeof...(Ts) == sizeof...(Us) && _::piecewise_ordered<tuple, tuple<Us...>>)
constexpr auto operator< (tuple const &lhs, tuple< Us... > const &rhs) noexcept
 Compares tuples for lexicographical is less relation.
 
template<typename... Us>
requires requires { rhs < lhs; }
KUMI_TRIVIAL friend constexpr auto operator<= (tuple const &lhs, tuple< Us... > const &rhs) noexcept
 Compares tuples for lexicographical is less or equal relation.
 
template<typename... Us>
requires requires { rhs < lhs; }
KUMI_TRIVIAL friend constexpr auto operator> (tuple const &lhs, tuple< Us... > const &rhs) noexcept
 Compares tuples for lexicographical is greater relation.
 
template<typename... Us>
requires requires { lhs < rhs; }
KUMI_TRIVIAL friend constexpr auto operator>= (tuple const &lhs, tuple< Us... > const &rhs) noexcept
 Compares tuples for lexicographical is greater relation relation.
 
template<typename... Us>
requires ( equality_comparable<tuple,tuple<Us...>> )
KUMI_TRIVIAL friend constexpr auto kumi::tuple< Ts >::operator!= (tuple const &self, tuple< Us... > const &other) noexcept
 

Tuple construction

template<typename... Ts>
 tuple (Ts &&...) -> tuple< typename std::unwrap_ref_decay< Ts >::type... >
 kumi::tuple deduction guide
 
template<typename... Ts>
KUMI_TRIVIAL_NODISCARD constexpr tuple< Ts &... > tie (Ts &...ts)
 Creates a kumi::tuple of lvalue references to its arguments.
 
template<typename... Ts>
KUMI_TRIVIAL_NODISCARD constexpr tuple< Ts &&... > forward_as_tuple (Ts &&...ts)
 Creates a kumi::tuple of forwarding references to its arguments.
 
template<typename... Ts>
KUMI_TRIVIAL_NODISCARD constexpr tuple< typename std::unwrap_ref_decay< Ts >::type... > make_tuple (Ts &&...ts)
 Creates a tuple object, deducing the target type from the types of arguments.
 
template<product_type Type>
KUMI_TRIVIAL_NODISCARD constexpr auto to_ref (Type &&t)
 Creates a kumi::tuple of references given a reference to a kumi::product_type.
 

Accessors

template<std::size_t I, typename... Ts>
decltype(auto) constexpr get (tuple< Ts... > &t) noexcept
 Extracts the Ith element from a kumi::tuple.