packages feed

pandoc-types 1.16 → 1.16.0.1

raw patch · 3 files changed

+38/−12 lines, 3 filesdep +deepseq

Dependencies added: deepseq

Files

Text/Pandoc/Definition.hs view
@@ -1,4 +1,4 @@-{-# LANGUAGE DeriveDataTypeable, DeriveGeneric, FlexibleContexts #-}+{-# LANGUAGE DeriveDataTypeable, DeriveGeneric, FlexibleContexts, CPP #-}  {- Copyright (C) 2006-2013 John MacFarlane <jgm@berkeley.edu>@@ -66,7 +66,11 @@ import Data.String import Data.Char (toLower) import Data.Monoid+#if MIN_VERSION_base(4,8,0)+import Control.DeepSeq+#else import Control.DeepSeq.Generics+#endif  data Pandoc = Pandoc Meta [Block]               deriving (Eq, Ord, Read, Show, Typeable, Data, Generic)@@ -343,6 +347,21 @@   where toJSON = toJSON'  -- Instances for deepseq+#if MIN_VERSION_base(4,8,0)+instance NFData MetaValue+instance NFData Meta+instance NFData Citation+instance NFData Alignment+instance NFData Inline+instance NFData MathType+instance NFData Format+instance NFData CitationMode+instance NFData QuoteType+instance NFData ListNumberDelim+instance NFData ListNumberStyle+instance NFData Block+instance NFData Pandoc+#else instance NFData MetaValue where rnf = genericRnf instance NFData Meta where rnf = genericRnf instance NFData Citation where rnf = genericRnf@@ -356,3 +375,4 @@ instance NFData ListNumberStyle where rnf = genericRnf instance NFData Block where rnf = genericRnf instance NFData Pandoc where rnf = genericRnf+#endif
Text/Pandoc/Walk.hs view
@@ -1,5 +1,10 @@-{-# LANGUAGE MultiParamTypeClasses, FlexibleInstances, ScopedTypeVariables,-    OverlappingInstances #-}+{-# LANGUAGE MultiParamTypeClasses, FlexibleInstances, ScopedTypeVariables, CPP #-}+#if MIN_VERSION_base(4,8,0)+#define OVERLAPS {-# OVERLAPPING #-}+#else+{-# LANGUAGE OverlappingInstances #-}+#define OVERLAPS+#endif {- Copyright (C) 2013 John MacFarlane <jgm@berkeley.edu> @@ -92,7 +97,8 @@   walkM f = T.mapM (walkM f)   query f = F.foldMap (query f) -instance (Walkable a b, Walkable a c) => Walkable a (b,c) where+instance OVERLAPS+        (Walkable a b, Walkable a c) => Walkable a (b,c) where   walk f (x,y)  = (walk f x, walk f y)   walkM f (x,y) = do x' <- walkM f x                      y' <- walkM f y@@ -417,8 +423,3 @@        return $ Citation id' pref' suff' mode notenum hash   query f (Citation id' pref suff mode notenum hash) =     query f pref <> query f suff--instance Walkable a b => Walkable a [b] where-  walk f xs  = map (walk f) xs-  walkM f xs = mapM (walkM f) xs-  query f xs = mconcat $ map (query f) xs
pandoc-types.cabal view
@@ -1,5 +1,5 @@ Name:                pandoc-types-Version:             1.16+Version:             1.16.0.1 Synopsis:            Types for representing a structured document Description:         @Text.Pandoc.Definition@ defines the 'Pandoc' data                      structure, which is used by pandoc to represent@@ -32,10 +32,12 @@ Category:            Text Build-type:          Simple Cabal-version:       >=1.6+Tested-With:         GHC == 7.4.2, GHC == 7.6.3, GHC == 7.8.4, GHC == 7.10.2 Extra-Source-Files:  changelog Source-repository    head   type:              git   location:          git://github.com/jgm/pandoc-types.git+ Library   Exposed-modules:   Text.Pandoc.Definition                      Text.Pandoc.Generic@@ -47,5 +49,8 @@                      syb >= 0.1 && < 0.7,                      ghc-prim >= 0.2,                      bytestring >= 0.9 && < 0.11,-                     aeson >= 0.6.2 && < 0.11,-                     deepseq-generics >= 0.1 && < 0.2+                     aeson >= 0.6.2 && < 0.11+  if impl(ghc < 7.10)+    Build-depends:   deepseq-generics >= 0.1 && < 0.2+  else+    Build-depends:   deepseq >= 1.4.1 && < 1.5