Derive Eq for defined types

This commit is contained in:
2025-05-20 12:17:43 -05:00
parent b9c6cc4470
commit 70761649ad

View File

@@ -14,9 +14,9 @@ import Text.Printf
type HeaderLevel = Int
newtype URL = URL {getUrl :: String}
newtype URL = URL {getUrl :: String} deriving (Eq)
newtype ImgPath = ImgPath {getPath :: String}
newtype ImgPath = ImgPath {getPath :: String} deriving (Eq)
parseMany :: ReadP a -> ReadP [a]
parseMany = Text.ParserCombinators.ReadP.many
@@ -40,6 +40,7 @@ data MdToken
| Italic MdToken
| Strikethrough MdToken
| Unit String
deriving (Eq)
-- Deriving Show for MdToken
instance Show MdToken where