mirror of
https://github.com/khibino/haskell-relational-record.git
synced 2024-11-29 06:37:03 +03:00
Add Eq instances.
This commit is contained in:
parent
f5179816da
commit
7676774782
@ -37,6 +37,9 @@ showDString (DString f) = f []
|
||||
isEmptyDString :: DString -> Bool
|
||||
isEmptyDString = null . showDString
|
||||
|
||||
instance Eq DString where
|
||||
x == y = showDString x == showDString y
|
||||
|
||||
instance Show DString where
|
||||
show = showDString
|
||||
|
||||
@ -139,3 +142,6 @@ wordShow :: Keyword -> String
|
||||
wordShow = d where
|
||||
d (Sequence s) = showDString s
|
||||
d w = show w
|
||||
|
||||
instance Eq Keyword where
|
||||
x == y = wordShow x == wordShow y
|
||||
|
Loading…
Reference in New Issue
Block a user