-- | Pretty print type signatures like
--
-- foo :: (Show x,Read x)
--     => (Foo -> Bar)
--     -> Maybe Int
--     -> (Char -> X -> Y)
--     -> IO ()
--
decl :: Decl NodeInfo -> Printer s ()
decl (TypeDecl _ head ty) =
  do write "type "
     pretty head
     write " = "
     (fits,st) <- fitsOnOneLine (pretty ty)
     if fits
        then put st
        else do newline
                indented 2 (pretty ty)
decl :: Decl NodeInfo -> Printer s ()
decl (TypeDecl _ head ty) =
  do write "type "
     pretty head
     write " = "
     (fits,st) <- fitsOnOneLine (pretty ty)
     if fits
        then put st
        else do newline
                indented 2 (pretty ty)
decl (TypeDecl _ head ty) =
  do write "type "
     pretty head
     write " = "
     (fits,st) <- fitsOnOneLine (pretty ty)
     if fits
        then put st
        else do newline
                indented 2 (pretty ty)