Skip to content

Commit

Permalink
Merge pull request #503 from well-typed/canonical-append-tf
Browse files Browse the repository at this point in the history
Define Append canonically
  • Loading branch information
phadej authored Dec 5, 2023
2 parents 40681b2 + 0561f0d commit f828003
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions optics-core/src/Optics/Internal/Optic/TypeLevel.hs
Original file line number Diff line number Diff line change
Expand Up @@ -73,8 +73,7 @@ type family Curry (xs :: IxList) (y :: Type) :: Type where

-- | Append two type-level lists together.
type family Append (xs :: [k]) (ys :: [k]) :: [k] where
Append '[] ys = ys -- needed for (<%>) and (%>)
Append xs '[] = xs -- needed for (<%)
Append '[] ys = ys
Append (x ': xs) ys = x ': Append xs ys

-- | Class that is inhabited by all type-level lists @xs@, providing the ability
Expand Down

0 comments on commit f828003

Please sign in to comment.