aboutsummaryrefslogtreecommitdiff
path: root/Logs/MapLog.hs
diff options
context:
space:
mode:
authorGravatar Joey Hess <joeyh@joeyh.name>2017-08-14 14:43:56 -0400
committerGravatar Joey Hess <joeyh@joeyh.name>2017-08-14 14:51:54 -0400
commita93ff12905005d1cbd2339ddeb8e8abfe2b20079 (patch)
tree79dcabdc88b955bfcfa46735fae666be87d6dae3 /Logs/MapLog.hs
parentaecfea27593bc121273fe53a6c11d4a22567004f (diff)
avoid accidental Show of VectorClock
Removed its Show instance.
Diffstat (limited to 'Logs/MapLog.hs')
-rw-r--r--Logs/MapLog.hs7
1 files changed, 3 insertions, 4 deletions
diff --git a/Logs/MapLog.hs b/Logs/MapLog.hs
index 7fe9e5782..a881eae34 100644
--- a/Logs/MapLog.hs
+++ b/Logs/MapLog.hs
@@ -19,7 +19,6 @@ module Logs.MapLog (
import Common
import Annex.VectorClock
-import Logs.TimeStamp
import Logs.Line
import qualified Data.Map as M
@@ -27,7 +26,7 @@ import qualified Data.Map as M
data LogEntry v = LogEntry
{ changed :: VectorClock
, value :: v
- } deriving (Eq, Show)
+ } deriving (Eq)
type MapLog f v = M.Map f (LogEntry v)
@@ -43,9 +42,9 @@ parseMapLog :: Ord f => (String -> Maybe f) -> (String -> Maybe v) -> String ->
parseMapLog fieldparser valueparser = M.fromListWith best . mapMaybe parse . splitLines
where
parse line = do
- let (ts, rest) = splitword line
+ let (sc, rest) = splitword line
(sf, sv) = splitword rest
- c <- VectorClock <$> parsePOSIXTime ts
+ c <- parseVectorClock sc
f <- fieldparser sf
v <- valueparser sv
Just (f, LogEntry c v)