|
Dedekind 0.0.0
A structuralist C++23 Module Library
|
The coalgebra of take<K>: the walk, until K elements are present. One more state, the count so far; O(1), no storage.
More...

Public Types | |
| using | Yield = std::invoke_result_t<const Coalg&, const S&> |
| using | Element = std::remove_cvref_t<decltype(std::declval<Yield>()->first)> |
Public Member Functions | |
| constexpr std::optional< std::pair< Element, std::pair< S, std::size_t > > > | operator() (const std::pair< S, std::size_t > &s) const |
Public Attributes | |
| Coalg | coalg |
The coalgebra of take<K>: the walk, until K elements are present. One more state, the count so far; O(1), no storage.