Skip to content

Commit 1ac7f17

Browse files
committed
Fixes for cabal-docspec
1 parent c8df1f6 commit 1ac7f17

File tree

2 files changed

+30
-18
lines changed

2 files changed

+30
-18
lines changed

scripts/test-cabal-docspec.sh

Lines changed: 14 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -20,10 +20,19 @@ if [ "${SKIP_CABAL_BUILD}" = "" ]; then
2020
fi
2121
fi
2222
cabal-docspec \
23-
--extra-package directory \
24-
--extra-package primitive \
25-
--extra-package lsm-tree:prototypes \
23+
-Wno-cpphs \
24+
-Wno-missing-module-file \
25+
-Wno-skipped-property \
26+
-XDerivingStrategies \
27+
-XDerivingVia \
28+
-XGeneralisedNewtypeDeriving \
2629
-XOverloadedStrings \
27-
-XNumericUnderscores \
30+
-XRankNTypes \
2831
-XTypeApplications \
29-
-XScopedTypeVariables
32+
-XTypeFamilies \
33+
-XNumericUnderscores \
34+
-XInstanceSigs \
35+
--extra-package directory \
36+
--extra-package lsm-tree:prototypes \
37+
--extra-package lsm-tree:blockio-api \
38+
--extra-package lsm-tree:blockio-sim

src/Database/LSMTree.hs

Lines changed: 16 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -278,21 +278,25 @@ This module is intended to be imported qualified, to avoid name clashes with Pre
278278
>>> :{
279279
import Database.LSMTree (BlobRef, Cursor, RawBytes, ResolveValue (..),
280280
SerialiseKey (..), SerialiseValue (..), Session, Table)
281-
import qualified Database.LSMTree as LSMT
282281
:}
283282
283+
>>> import qualified Database.LSMTree as LSMT
284+
284285
=== Defining key, value, and BLOB types
285286
286287
The examples in this module use the types @Key@, @Value@, and @Blob@ for keys, values and BLOBs.
287288
288-
>>> :{
289-
import Control.Exception (bracket)
290-
import Data.ByteString (ByteString)
291-
import Data.ByteString.Short (ShortByteString)
292-
import Data.Proxy (Proxy)
293-
import Data.String (IsString)
294-
import Data.Word (Word64)
295-
:}
289+
>>> import Control.Exception (bracket)
290+
291+
>>> import Data.ByteString (ByteString)
292+
293+
>>> import Data.ByteString.Short (ShortByteString)
294+
295+
>>> import Data.Proxy (Proxy)
296+
297+
>>> import Data.String (IsString)
298+
299+
>>> import Data.Word (Word64)
296300
297301
The type @Key@ is a newtype wrapper around 'Data.Word.Word64'.
298302
The required instance of 'SerialiseKey' is derived by @GeneralisedNewtypeDeriving@ from the preexisting instance for 'Data.Word.Word64'.
@@ -343,10 +347,9 @@ The examples in this module are wrapped in a call to @runExample@,
343347
which creates a temporary session directory and
344348
runs the example with access to an open 'Session' and a fresh 'Table'.
345349
346-
>>> :{
347-
import qualified System.Directory as Dir
348-
import System.FilePath ((</>))
349-
:}
350+
>>> import qualified System.Directory as Dir
351+
352+
>>> import System.FilePath ((</>))
350353
351354
>>> :{
352355
runExample :: (Session IO -> Table IO Key Value Blob -> IO a) -> IO a

0 commit comments

Comments
 (0)