arrow-optics / arrow.optics.typeclasses / Snoc / snoc

snoc

abstract fun snoc(): Prism<S, Tuple2<S, A>>

Provides a Prism between a S and its init and last element A.

open infix fun S.snoc(last: A): S

Append an element A to S.

Do you like Arrow?

Arrow Org
<