diff options
author | simonpj@microsoft.com <unknown> | 2009-04-23 09:39:45 +0000 |
---|---|---|
committer | simonpj@microsoft.com <unknown> | 2009-04-23 09:39:45 +0000 |
commit | 72edf508ec424d744376eda2c4191e3c45111bce (patch) | |
tree | 15605d55e029cd11d46fca4d61447c9f2a06dbd5 /compiler | |
parent | 81709fc3e51b7d328d42367e307ce6af728da7de (diff) | |
download | haskell-72edf508ec424d744376eda2c4191e3c45111bce.tar.gz |
Better pretty-printing for IdDetails
Diffstat (limited to 'compiler')
-rw-r--r-- | compiler/basicTypes/IdInfo.lhs | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/compiler/basicTypes/IdInfo.lhs b/compiler/basicTypes/IdInfo.lhs index 9889dbc198..fb18c81085 100644 --- a/compiler/basicTypes/IdInfo.lhs +++ b/compiler/basicTypes/IdInfo.lhs @@ -277,7 +277,6 @@ instance Outputable IdDetails where pprIdDetails :: IdDetails -> SDoc pprIdDetails VanillaId = empty -pprIdDetails (RecSelId {}) = ptext (sLit "[RecSel]") pprIdDetails (DataConWorkId _) = ptext (sLit "[DataCon]") pprIdDetails (DataConWrapId _) = ptext (sLit "[DataConWrapper]") pprIdDetails (ClassOpId _) = ptext (sLit "[ClassOp]") @@ -285,11 +284,14 @@ pprIdDetails (PrimOpId _) = ptext (sLit "[PrimOp]") pprIdDetails (FCallId _) = ptext (sLit "[ForeignCall]") pprIdDetails (TickBoxOpId _) = ptext (sLit "[TickBoxOp]") pprIdDetails DFunId = ptext (sLit "[DFunId]") +pprIdDetails (RecSelId { sel_naughty = is_naughty }) + = brackets $ ptext (sLit "RecSel") <> pp_naughty + where + pp_naughty | is_naughty = ptext (sLit "(naughty)") + | otherwise = empty \end{code} - - %************************************************************************ %* * \subsection{The main IdInfo type} |