packages feed

trifecta 1.6.1 → 1.6.2

raw patch · 2 files changed

+14/−6 lines, 2 filesdep ~blaze-htmldep ~blaze-markup

Dependency ranges changed: blaze-html, blaze-markup

Files

src/Text/Trifecta/Highlight.hs view
@@ -94,9 +94,9 @@ instance ToMarkup HighlightedRope where   toMarkup (HighlightedRope intervals r) = Html5.pre $ go 0 lbs effects where     lbs = L.fromChunks [bs | Strand bs _ <- F.toList (strands r)]-    ln no = Html5.a ! name (toValue $ "line-" ++ show no) $ Empty+    ln no = Html5.a ! name (toValue $ "line-" ++ show no) $ emptyMarkup     effects = sort $ [ i | (Interval lo hi, tok) <- intersections mempty (delta r) intervals-                     , i <- [ (Leaf "span" "<span" ">" ! class_ (toValue $ show tok)) :@ bytes lo+                     , i <- [ (leafMarkup "span" "<span" ">" ! class_ (toValue $ show tok)) :@ bytes lo                             , preEscapedToHtml ("</span>" :: String) :@ bytes hi                             ]                      ] ++ imap (\k i -> ln k :@ i) (L.elemIndices '\n' lbs)@@ -105,6 +105,14 @@       | eb <= b = eff >> go b cs es       | otherwise = unsafeLazyByteString om >> go eb nom es          where (om,nom) = L.splitAt (fromIntegral (eb - b)) cs++#if MIN_VERSION_blaze_markup(0,8,0)+    emptyMarkup = Empty ()+    leafMarkup a b c = Leaf a b c ()+#else+    emptyMarkup = Empty+    leafMarkup a b c = Leaf a b c+#endif  instance Pretty HighlightedRope where   pretty (HighlightedRope intervals r) = go mempty lbs boundaries where
trifecta.cabal view
@@ -1,6 +1,6 @@ name:          trifecta category:      Text, Parsing, Diagnostics, Pretty Printer, Logging-version:       1.6.1+version:       1.6.2 license:       BSD3 cabal-version: >= 1.10 license-file:  LICENSE@@ -20,7 +20,7 @@  source-repository head   type: git-  location: git://github.com/ekmett/trifecta.git+  location: https://github.com/ekmett/trifecta  library   exposed-modules:@@ -46,8 +46,8 @@     array                >= 0.3.0.2 && < 0.6,     base                 >= 4.4     && < 5,     blaze-builder        >= 0.3.0.1 && < 0.5,-    blaze-html           >= 0.5     && < 0.9,-    blaze-markup         >= 0.5     && < 0.8,+    blaze-html           >= 0.5     && < 0.10,+    blaze-markup         >= 0.5     && < 0.9,     bytestring           >= 0.9.1   && < 0.11,     charset              >= 0.3.5.1 && < 1,     comonad              >= 4       && < 6,