diff options
author | John MacFarlane <jgm@berkeley.edu> | 2018-03-16 08:23:34 -0700 |
---|---|---|
committer | John MacFarlane <jgm@berkeley.edu> | 2018-03-16 08:23:34 -0700 |
commit | 0b5712e69b054442ccb10be3c1aab4f8dcdb7efd (patch) | |
tree | 8de14dbafb7a24ca0b79ad553a8587d5cd5bf71b /src/Text/Pandoc/Class.hs | |
parent | 8360f9dedfc7298c2807c2e0911dd51fc2acbc3e (diff) | |
download | pandoc-0b5712e69b054442ccb10be3c1aab4f8dcdb7efd.tar.gz |
Class: Semigroup instance for FileTree with base >= 4.9.
Diffstat (limited to 'src/Text/Pandoc/Class.hs')
-rw-r--r-- | src/Text/Pandoc/Class.hs | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/Text/Pandoc/Class.hs b/src/Text/Pandoc/Class.hs index aa0379942..f7544433c 100644 --- a/src/Text/Pandoc/Class.hs +++ b/src/Text/Pandoc/Class.hs @@ -923,7 +923,11 @@ data FileInfo = FileInfo { infoFileMTime :: UTCTime } newtype FileTree = FileTree {unFileTree :: M.Map FilePath FileInfo} +#if MIN_VERSION_base(4,9,0) + deriving (Semigroup, Monoid) +#else deriving (Monoid) +#endif getFileInfo :: FilePath -> FileTree -> Maybe FileInfo getFileInfo fp tree = |