Skip to content

Commit

Permalink
Code formatting
Browse files Browse the repository at this point in the history
  • Loading branch information
taig committed Nov 20, 2024
1 parent 7b3f5c2 commit 5455fc0
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@ object EnumerationValues:

def apply[A, B](values: NonEmptyList[B]): EnumerationValues.Aux[A, B] = new EnumerationValues[A]:
override type Out = B

override def toNonEmptyList: NonEmptyList[Out] = values

inline given [A](using
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ object Mapping:
merge: (C, C) => C,
split: C => Option[(C, C)]
): Mapping[(A, B), C] = new Mapping[(A, B), C]:
override val values: NonEmptyList[(A, B)] = left.values.flatMap(a => right.values.map(b => (a, b)))
override val values: NonEmptyList[(A, B)] = left.values.flatMap(right.values.tupleLeft)
override def inj: ((A, B)) => C = { case (a, b) => merge(left.inj(a), right.inj(b)) }
override def prj: C => Option[(A, B)] = c => split(c).flatMap { case (a, b) => (left.prj(a), right.prj(b)).tupled }

Expand Down

0 comments on commit 5455fc0

Please sign in to comment.