arrow-optics / arrow.optics.typeclasses / Cons / cons
abstract fun cons():
Prism
<S, Tuple2<A, S>>
Provides a Prism between S and its first element A and tail S.
open infix fun A.cons(tail: S): S
Prepend an element A to the first element of S.
Receiver A element to prepend or attach on left side of tail.
Do you like Arrow?
✖