ComposerPathIndependenceLaws

dev.constructive.eo.laws.typeclass.ComposerPathIndependenceLaws

C1 — path independence. An Iso → Affine via Tuple2 vs via Either should be modify-equivalent.

Attributes

Source
ComposerLaws.scala
Graph
Supertypes
class Object
trait Matchable
class Any

Members list

Value members

Abstract methods

def iso: Optic[S, S, A, A, Direct]

The optic under test.

The optic under test.

Attributes

Source
ComposerLaws.scala

Concrete methods

def pathIndependence(s: S, f: A => A): Boolean

Direct→Tuple2→Affine and Direct→Either→Affine agree on modify.

Direct→Tuple2→Affine and Direct→Either→Affine agree on modify.

Attributes

Source
ComposerLaws.scala