Commit b214d1cb authored by Ian Lynagh's avatar Ian Lynagh

Unconditionally derive some instances

They used to be only derived when DEBUG was on
parent b8f6ca66
......@@ -98,10 +98,7 @@ data RealSrcLoc
= SrcLoc FastString -- A precise location (file name)
{-# UNPACK #-} !Int -- line number, begins at 1
{-# UNPACK #-} !Int -- column number, begins at 1
#ifdef DEBUG
deriving Show -- debugging
#endif
deriving Show
data SrcLoc
= RealSrcLoc {-# UNPACK #-}!RealSrcLoc
......@@ -254,24 +251,16 @@ data RealSrcSpan
srcSpanLine :: {-# UNPACK #-} !Int,
srcSpanCol :: {-# UNPACK #-} !Int
}
#ifdef DEBUG
deriving (Eq, Typeable, Show) -- Show is used by Lexer.x, becuase we
-- derive Show for Token
#else
deriving (Eq, Typeable)
#endif
data SrcSpan =
RealSrcSpan !RealSrcSpan
| UnhelpfulSpan !FastString -- Just a general indication
-- also used to indicate an empty span
#ifdef DEBUG
deriving (Eq, Typeable, Show) -- Show is used by Lexer.x, becuase we
-- derive Show for Token
#else
deriving (Eq, Typeable)
#endif
-- | Built-in "bad" 'SrcSpan's for common sources of location uncertainty
noSrcSpan, wiredInSrcSpan :: SrcSpan
......
......@@ -169,9 +169,7 @@ data CmmToken
| CmmT_Int Integer
| CmmT_Float Rational
| CmmT_EOF
#ifdef DEBUG
deriving (Show)
#endif
-- -----------------------------------------------------------------------------
-- Lexer actions
......
......@@ -584,9 +584,7 @@ data Token
| ITlineComment String -- comment starting by "--"
| ITblockComment String -- comment in {- -}
#ifdef DEBUG
deriving Show -- debugging
#endif
deriving Show
-- the bitmap provided as the third component indicates whether the
-- corresponding extension keyword is valid under the extension options
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment