From 2163981e773b76212b2265a1eb03208ee2e7edf2 Mon Sep 17 00:00:00 2001 From: Alex Biehl Date: Mon, 1 May 2017 17:40:36 +0200 Subject: Lazily decode docMap and argMap (#610) These are only used in case of a doc reexport so most of the time decoding these is wasted work. --- haddock-api/src/Haddock/InterfaceFile.hs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'haddock-api/src/Haddock') diff --git a/haddock-api/src/Haddock/InterfaceFile.hs b/haddock-api/src/Haddock/InterfaceFile.hs index 78853a79..3365581f 100644 --- a/haddock-api/src/Haddock/InterfaceFile.hs +++ b/haddock-api/src/Haddock/InterfaceFile.hs @@ -83,7 +83,7 @@ binaryInterfaceMagic = 0xD0Cface -- binaryInterfaceVersion :: Word16 #if (__GLASGOW_HASKELL__ >= 802) && (__GLASGOW_HASKELL__ < 804) -binaryInterfaceVersion = 29 +binaryInterfaceVersion = 30 binaryInterfaceVersionCompatibility :: [Word16] binaryInterfaceVersionCompatibility = [binaryInterfaceVersion] @@ -377,6 +377,7 @@ instance Binary InstalledInterface where put_ bh modu put_ bh is_sig put_ bh info + lazyPut bh (docMap, argMap) put_ bh docMap put_ bh argMap put_ bh exps @@ -389,8 +390,7 @@ instance Binary InstalledInterface where modu <- get bh is_sig <- get bh info <- get bh - docMap <- get bh - argMap <- get bh + ~(docMap, argMap) <- lazyGet bh exps <- get bh visExps <- get bh opts <- get bh -- cgit v1.2.3