1
1
mirror of https://github.com/github/semantic.git synced 2024-12-23 14:54:16 +03:00

Define an Eq1 instance for Comment.

This commit is contained in:
Rob Rix 2017-04-06 10:39:22 -04:00
parent 7f401c4e08
commit 5166900702

View File

@ -1,10 +1,14 @@
module Data.Syntax.Comment where module Data.Syntax.Comment where
import Data.Functor.Classes.Eq.Generic
import GHC.Generics
import Prologue import Prologue
-- | An unnested comment (line or block). -- | An unnested comment (line or block).
newtype Comment a = Comment { commentContent :: ByteString } newtype Comment a = Comment { commentContent :: ByteString }
deriving (Eq, Show) deriving (Eq, Generic1, Show)
instance Eq1 Comment where liftEq = genericLiftEq
-- TODO: nested comment types -- TODO: nested comment types
-- TODO: documentation comment types -- TODO: documentation comment types