diff options
author | Ben Gamari <ben@smart-cactus.org> | 2017-09-13 17:02:36 -0400 |
---|---|---|
committer | Ben Gamari <ben@smart-cactus.org> | 2018-01-18 13:04:12 -0500 |
commit | 9b3965237c22cb65a8f3d023ab9e1f22a86224b8 (patch) | |
tree | 78b68d7b700152b2094af99d6b88f564c13a06da | |
parent | 19ee8ab4935cae4d9806c30f6cd581360e63042d (diff) | |
download | haskell-wip/prettyprinter.tar.gz |
More cleanupswip/prettyprinter
-rw-r--r-- | compiler/utils/Pretty.hs | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/compiler/utils/Pretty.hs b/compiler/utils/Pretty.hs index d876972073..a085e11d88 100644 --- a/compiler/utils/Pretty.hs +++ b/compiler/utils/Pretty.hs @@ -121,10 +121,9 @@ import qualified Data.Text as T import qualified Data.Text.Lazy as TL import qualified Data.Text.Lazy.IO as TL -import Data.Text.Prettyprint.Doc --- PI = PrettyprinterInternal -import Data.Text.Prettyprint.Doc.Internal as PI - +import Data.Text.Prettyprint.Doc hiding (vcat) +import qualified Data.Text.Prettyprint.Doc as P +import qualified Data.Text.Prettyprint.Doc.Internal as PI import Data.Text.Prettyprint.Doc.Render.Text import GHC.Float (float2Double) @@ -221,6 +220,8 @@ infixl 5 $$, $+$ ($$) :: Doc a -> Doc a -> Doc a ($$) = ($+$) +vcat :: [Doc a] -> Doc a +vcat = foldr ($$) mempty -- --------------------------------------------------------------------------- -- The Doc data type |