Pretty-print an empty list of fundeps without '|' (should fix #1260)
authorStefan O'Rear <stefanor@cox.net>
Mon, 2 Apr 2007 15:28:54 +0000 (15:28 +0000)
committerStefan O'Rear <stefanor@cox.net>
Mon, 2 Apr 2007 15:28:54 +0000 (15:28 +0000)
libraries/template-haskell/Language/Haskell/TH/Ppr.hs

index 55023f1..d2c64d9 100644 (file)
@@ -229,6 +229,7 @@ instance Ppr Dec where
 ------------------------------
 instance Ppr FunDep where
     ppr (FunDep xs ys) = hsep (map ppr xs) <+> text "->" <+> hsep (map ppr ys)
+    ppr_list [] = empty
     ppr_list xs = char '|' <+> sep (punctuate (text ", ") (map ppr xs))
 
 ------------------------------