/** * Constructs an `Equivalence>` given an `Equivalence` and an * `Equivalence`. The instance will compare the `Either` values and if * both are `Right` or `Left` compare them for equality. * * @tsplus fluent Equivalence orElseEither */ export function orElseEither_( self: Equivalence, that: LazyArg> ): Equivalence> { return Equivalence((ex, ey) => ex._tag === "Left" && ey._tag === "Left" ? self.equals(ex.left, ey.left) : ex._tag === "Right" && ey._tag === "Right" ? that().equals(ex.right, ey.right) : false ) } /** * Constructs an `Equivalence>` given an `Equivalence` and an * `Equivalence`. The instance will compare the `Either` values and if * both are `Right` or `Left` compare them for equality. * * @tsplus static Equivalence/Aspects orElseEither */ export const orElseEither = Pipeable(orElseEither_)