packages feed

doclayout 0.4 → 0.4.0.1

raw patch · 4 files changed

+18/−3 lines, 4 filesPVP ok

version bump matches the API change (PVP)

API changes (from Hackage documentation)

Files

changelog.md view
@@ -1,5 +1,10 @@ # doclayout +## 0.4.0.1++  * Add clause for Empty to renderList (#22).+  * Remove upper bound for criterion+ ## 0.4    * Expose `unfoldD` [API change].
doclayout.cabal view
@@ -1,5 +1,5 @@ name:                doclayout-version:             0.4+version:             0.4.0.1 synopsis:            A prettyprinting library for laying out text documents. description:         doclayout is a prettyprinting library for laying out                      text documents, with several features not present@@ -57,7 +57,7 @@   Hs-Source-Dirs:  bench   Build-Depends:   doclayout,                    base >= 4.8 && < 5,-                   criterion >= 1.0 && < 1.6,+                   criterion >= 1.0,                    deepseq,                    text,                    emojis >= 0.1.2,
src/Text/DocLayout.hs view
@@ -367,6 +367,8 @@ renderList :: HasChars a => [Doc a] -> DocState a renderList [] = return () +renderList (Empty : xs) = renderList xs+ renderList (Text off s : xs) = do   outp off s   renderList xs
test/test.hs view
@@ -15,8 +15,11 @@ import Data.Semigroup #endif +timeout :: Integer+timeout = 480 * 10^(6 :: Int)+ main :: IO ()-main = defaultMain $ localOption (mkTimeout (480 * 10^6)) $ testGroup "Tests" tests+main = defaultMain $ localOption (mkTimeout timeout) $ testGroup "Tests" tests -- 8 minute timeout  renderTest :: String -> Maybe Int -> Doc Text -> Text -> TestTree@@ -33,6 +36,11 @@       Nothing       (lblock 4 (text "hi there" :: Doc Text))       "hi t\nhere"++  , renderTest "lblock with blank line"+      Nothing+      (Block 5 ["a", "", "b"] :: Doc Text)+      "a\nb"    , renderTest "nesting should not wrap"       (Just 10)