Lumiera
0.pre.03
»edit your freedom«
|
Go to the source code of this file.
Some small helpers and convenience shortcuts to ease working with collections and sequences (given by iterator).
Mostly, these are tiny bits of existing functionality, just packaged in a more fluent and readable way.
Definition in file util-coll.hpp.
Classes | |
struct | can_direct_access_Last< T > |
struct | treat_as_LumieraIterator< T > |
struct | treat_as_STL_Container< T > |
Functions | |
template<typename COL > | |
void | __ensure_nonempty (COL const &coll) |
template<typename COLL > | |
enable_if< treat_as_STL_Container< COLL >, typename COLL::reference > | first (COLL const &coll) |
access the first element of a STL-like container. More... | |
template<typename IT > | |
enable_if< treat_as_LumieraIterator< IT >, typename IT::reference > | first (IT ii) |
extract the first element yielded by an Lumiera Forward Iterator. More... | |
template<typename COLL > | |
enable_if< can_direct_access_Last< COLL >, typename COLL::reference > | last (COLL const &coll) |
access the last element of a STL-like container. More... | |
template<class IT > | |
auto | max (IT &&elms) |
template<class CON > | |
auto | max (CON const &elms) |
template<class IT > | |
auto | min (IT &&elms) |
template<class CON > | |
auto | min (CON const &elms) |
Namespaces |
|
inline |
access the first element of a STL-like container.
const&
and the const
is stripped before access. Definition at line 112 of file util-coll.hpp.
References util::first().
Referenced by util::first().
|
inline |
access the last element of a STL-like container.
const&
and the const
is stripped before access. Definition at line 128 of file util-coll.hpp.
References util::last().
Referenced by util::last().
|
inline |
extract the first element yielded by an Lumiera Forward Iterator.
Definition at line 144 of file util-coll.hpp.
References util::first().