1
1
mirror of https://github.com/github/semantic.git synced 2024-12-22 06:11:49 +03:00

Define a GEq1 instance for :*: with GEq1 fields.

This commit is contained in:
Rob Rix 2017-02-21 16:19:23 -05:00
parent 2fab8ef27a
commit 98f733cf46

View File

@ -40,3 +40,6 @@ instance (GEq1 f, GEq1 g) => GEq1 (f :+: g) where
(L1 a, L1 b) -> gliftEq f a b
(R1 a, R1 b) -> gliftEq f a b
_ -> False
instance (GEq1 f, GEq1 g) => GEq1 (f :*: g) where
gliftEq f (a1 :*: b1) (a2 :*: b2) = gliftEq f a1 a2 && gliftEq f b1 b2