diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md
index 65b4d4b28..69c90e359 100644
--- a/CONTRIBUTING.md
+++ b/CONTRIBUTING.md
@@ -20,7 +20,7 @@ has to be enabled, either by setting the flag in
executable using `--flag=+serialblockio`.
> :warning: **When enabling `serialblockio`, disable the
-> `cabal.project.blockio-uring` import in `cabal.project`!** Unforunately, this
+> `cabal.project.blockio-uring` import in `cabal.project`!** Unfortunately, this
> line has to be removed/commented out manually (for now), or the project won't
> build.
diff --git a/README.md b/README.md
index 728aa7e6e..a20d657f8 100644
--- a/README.md
+++ b/README.md
@@ -26,7 +26,7 @@ It has support for:
- Monoidal upserts which combine the stored and new values.
-- BLOB storage which assocates a large auxiliary BLOB with a key.
+- BLOB storage which associates a large auxiliary BLOB with a key.
- Durable on-disk persistence and rollback via named snapshots.
@@ -78,7 +78,7 @@ LSM-trees can be used concurrently, but with a few restrictions:
cannot be accessed from different processes at the same time.
- Tables can be used concurrently and concurrent use of read operations
- such as lookups is determinstic. However, concurrent use of write
+ such as lookups is deterministic. However, concurrent use of write
operations such as insert or delete with any other operation results
in a race condition.
@@ -318,7 +318,7 @@ The worst-case in-memory size of an LSM-tree is *O*(*n*).
A compact index stores the 64 most significant bits of the minimum
serialised key for each memory page, as well as 1 bit per memory page
to resolve clashes, 1 bit per memory page to mark overflow pages, and
- a negligable amount of memory for tie breakers. The total in-memory
+ a negligible amount of memory for tie breakers. The total in-memory
size of all indexes is approximately 66 bits per memory page.
The total size of an LSM-tree must not exceed 241 physical
diff --git a/bench/micro/Bench/Database/LSMTree/Internal/Index/Compact.hs b/bench/micro/Bench/Database/LSMTree/Internal/Index/Compact.hs
index 0b2582c7a..76447d983 100644
--- a/bench/micro/Bench/Database/LSMTree/Internal/Index/Compact.hs
+++ b/bench/micro/Bench/Database/LSMTree/Internal/Index/Compact.hs
@@ -91,7 +91,7 @@ constructIndexCompact (ChunkSize csize) apps = runST $ do
Benchmarks for UTxO keys that are /almost/ uniformly distributed
-------------------------------------------------------------------------------}
--- | UTXO keys are not truly uniformly distrbuted. The 'txId' is a uniformly
+-- | UTXO keys are not truly uniformly distributed. The 'txId' is a uniformly
-- distributed hash, but the same 'txId' can appear in multiple UTXO keys, but
-- with a different 'txIx'. In the worst case, this means that we have a clash
-- in the compact index for /every page/. The following benchmarks show
diff --git a/blockio/src-sim/System/FS/BlockIO/Sim.hs b/blockio/src-sim/System/FS/BlockIO/Sim.hs
index d6d88621b..cc202daac 100644
--- a/blockio/src-sim/System/FS/BlockIO/Sim.hs
+++ b/blockio/src-sim/System/FS/BlockIO/Sim.hs
@@ -54,7 +54,7 @@ fromHasFS hfs =
-- | Lock files are reader\/writer locks.
--
-- We implement this using the content of the lock file. The content is a
--- counter, positive for readers and negaive (specifically -1) for writers.
+-- counter, positive for readers and negative (specifically -1) for writers.
-- There can be any number of readers, but only one writer. Writers can not
-- coexist with readers.
--
diff --git a/blockio/src/System/FS/BlockIO/API.hs b/blockio/src/System/FS/BlockIO/API.hs
index 8b9756959..4b25640cb 100644
--- a/blockio/src/System/FS/BlockIO/API.hs
+++ b/blockio/src/System/FS/BlockIO/API.hs
@@ -111,7 +111,7 @@ data HasBlockIO m h = HasBlockIO {
-- function in 'IO' much more complex. In particular, if we want to reuse
-- "GHC.IO.Handle.Lock" functionality, then we have to either ...
--
- -- 1. Convert there and back between OS-specific file desciptors and
+ -- 1. Convert there and back between OS-specific file descriptors and
-- 'GHC.Handle's, which is not possible on Windows without creating new
-- file descriptors, or ...
-- 2. Vendor all of the "GHC.IO.Handle.Lock" code and its dependencies
@@ -131,7 +131,7 @@ data HasBlockIO m h = HasBlockIO {
-- | Synchronise file contents with the storage device.
--
-- Ensure that all change to the file handle's contents which exist only in
- -- memory (as buffered system cache pages) are transfered/flushed to disk.
+ -- memory (as buffered system cache pages) are transferred/flushed to disk.
-- This will also update the file handle's associated metadata.
--
-- This uses different system calls on different distributions.
diff --git a/bloomfilter/src/Data/BloomFilter/Hash.hs b/bloomfilter/src/Data/BloomFilter/Hash.hs
index 0dc6a0bf1..8548a5905 100644
--- a/bloomfilter/src/Data/BloomFilter/Hash.hs
+++ b/bloomfilter/src/Data/BloomFilter/Hash.hs
@@ -279,7 +279,7 @@ https://github.com/facebook/rocksdb/blob/096fb9b67d19a9a180e7c906b4a0cdb2b2d0c1f
-}
--- | Evalute 'CheapHashes' family.
+-- | Evaluate 'CheapHashes' family.
--
-- \[
-- g_i = h_0 + \left\lfloor h_1 / 2^i \right\rfloor
diff --git a/doc/format-page.md b/doc/format-page.md
index e41cc5e25..0ecae38ab 100644
--- a/doc/format-page.md
+++ b/doc/format-page.md
@@ -226,7 +226,7 @@ representation gives natural alignment without any padding.
If the blob reference bitmap indicates that there is a blob reference for key i,
then the index in the blob reference array can be found by counting the number
-of 1 bits for all bitmap indexes stricly less than i. This can be done
+of 1 bits for all bitmap indexes strictly less than i. This can be done
relatively efficiently using the popcount CPU instruction. For example, pages
with up to 64 keys, the bitmap fits into a single 64bit word and thus a single
popcount instruction, (and some bit shifting and masking) is needed to find the
diff --git a/doc/format-run.md b/doc/format-run.md
index 46fc872f3..74e986c2d 100644
--- a/doc/format-run.md
+++ b/doc/format-run.md
@@ -134,7 +134,7 @@ vector.
The first 4 bytes (32bit) are a format identifier / format version. This
determines the format of the rest of the header and file.
-The format identifier also acts as endianess marker.
+The format identifier also acts as endianness marker.
It (and remaining fields) are serialised in native byte order.
The remainder of the header for format 1 consists of:
diff --git a/lsm-tree.cabal b/lsm-tree.cabal
index a502b9e1e..e289dfc6d 100644
--- a/lsm-tree.cabal
+++ b/lsm-tree.cabal
@@ -10,7 +10,7 @@ description:
* Basic key–value operations, such as lookup, insert, and delete.
* Range lookups, which efficiently retrieve the values for all keys in a given range.
* Monoidal upserts which combine the stored and new values.
- * BLOB storage which assocates a large auxiliary BLOB with a key.
+ * BLOB storage which associates a large auxiliary BLOB with a key.
* Durable on-disk persistence and rollback via named snapshots.
* Cheap table duplication where all duplicates can be independently accessed and modified.
* High-performance lookups on SSDs using I\/O batching and parallelism.
@@ -47,7 +47,7 @@ description:
* Each session locks its session directory.
This means that a database cannot be accessed from different processes at the same time.
- * Tables can be used concurrently and concurrent use of read operations such as lookups is determinstic.
+ * Tables can be used concurrently and concurrent use of read operations such as lookups is deterministic.
However, concurrent use of write operations such as insert or delete with any other operation results in a race condition.
== Performance #performance#
@@ -172,7 +172,7 @@ description:
An ordinary index stores the maximum serialised key for each memory page.
The total in-memory size of all indexes is proportional to the average size of one serialised key per memory page.
[@CompactIndex@]:
- A compact index stores the 64 most significant bits of the minimum serialised key for each memory page, as well as 1 bit per memory page to resolve clashes, 1 bit per memory page to mark overflow pages, and a negligable amount of memory for tie breakers.
+ A compact index stores the 64 most significant bits of the minimum serialised key for each memory page, as well as 1 bit per memory page to resolve clashes, 1 bit per memory page to mark overflow pages, and a negligible amount of memory for tie breakers.
The total in-memory size of all indexes is approximately 66 bits per memory page.
The total size of an LSM-tree must not exceed \(2^{41}\) physical entries.
diff --git a/prototypes/ScheduledMerges.hs b/prototypes/ScheduledMerges.hs
index 1da764362..c444335dd 100644
--- a/prototypes/ScheduledMerges.hs
+++ b/prototypes/ScheduledMerges.hs
@@ -656,7 +656,7 @@ newMergingRun mergeType runs = do
assertST $ length runs > 1
-- in some cases, no merging is required at all
(debt, state) <- case filter (\r -> runSize r > 0) runs of
- [] -> let (r:_) = runs -- just re-use the empty input
+ [] -> let (r:_) = runs -- just reuse the empty input
in return (runSize r, CompletedMerge r)
[r] -> return (runSize r, CompletedMerge r)
rs -> do
diff --git a/src-control/Control/ActionRegistry.hs b/src-control/Control/ActionRegistry.hs
index ad679ea8f..5c8632643 100644
--- a/src-control/Control/ActionRegistry.hs
+++ b/src-control/Control/ActionRegistry.hs
@@ -292,7 +292,7 @@ mapActionError f (ActionError e) = ActionError (f e)
--
-- If the code was interrupted due to an exception for example, then the
-- registry is aborted, which performs registered rollback actions. If the code
--- succesfully terminated, then the registry is committed, in which case
+-- successfully terminated, then the registry is committed, in which case
-- registered, delayed actions will be performed.
--
-- Registered actions are run in LIFO order, whether they be rollback actions or
@@ -481,7 +481,7 @@ mapExceptionWithActionRegistry f action = action `catch` (throwIO . mapSomeExcep
Rollback actions and delayed actions are performed /precisely/ when aborting
or committing an action registry respectively (see [Action
registry](#g:actionRegistry)). To achieve this, finalisation of the action
- registry happens in the same masked state as runnning the registered actions.
+ registry happens in the same masked state as running the registered actions.
This means all the usual masking caveats apply for the registered actions.
-}
diff --git a/src-control/Control/RefCount.hs b/src-control/Control/RefCount.hs
index 7fcfe6767..35b9c8c3f 100644
--- a/src-control/Control/RefCount.hs
+++ b/src-control/Control/RefCount.hs
@@ -457,7 +457,7 @@ data Enabled a = Enabled !a | Disabled
globalForgottenRef :: IORef (Enabled (Maybe (RefId, CallStack)))
globalForgottenRef = unsafePerformIO $ newIORef (Enabled Nothing)
--- | This version of 'unsafeIOToPrim' is strict in the result of the arument
+-- | This version of 'unsafeIOToPrim' is strict in the result of the argument
-- action.
--
-- Without strictness it seems that some IO side effects are not happening at
@@ -580,7 +580,7 @@ checkForgottenRefs = do
_unused = throwIO @m @SomeException
-- | Ignore and reset the state of forgotten reference tracking. This ensures
--- that any stale fogotten references are not reported later.
+-- that any stale forgotten references are not reported later.
--
-- This is especillay important in QC tests with shrinking which otherwise
-- leads to confusion.
diff --git a/src-extras/Database/LSMTree/Extras/ReferenceImpl.hs b/src-extras/Database/LSMTree/Extras/ReferenceImpl.hs
index da32a9936..8eb110499 100644
--- a/src-extras/Database/LSMTree/Extras/ReferenceImpl.hs
+++ b/src-extras/Database/LSMTree/Extras/ReferenceImpl.hs
@@ -134,7 +134,7 @@ instance Arbitrary PageContentOrdered where
shrink (PageContentOrdered kops) =
map PageContentOrdered (shrinkOrderedKeyOps kops)
--- | Stricly increasing, so no duplicates.
+-- | Strictly increasing, so no duplicates.
pageContentOrderedInvariant :: PageContentOrdered -> Bool
pageContentOrderedInvariant (PageContentOrdered kops) =
pageContentFitsInvariant (PageContentFits kops)
diff --git a/src-kmerge/KMerge/Heap.hs b/src-kmerge/KMerge/Heap.hs
index 033f3fb42..f3b2453ae 100644
--- a/src-kmerge/KMerge/Heap.hs
+++ b/src-kmerge/KMerge/Heap.hs
@@ -9,7 +9,7 @@
-- (internally the filling of root value and sifting down is delayed).
--
-- Also there isn't *insert* operation, i.e. the heap can only shrink.
--- Other heap usual heap opeartions are *create-heap*, *extract-min* and *replace*.
+-- Other heap usual heap operations are *create-heap*, *extract-min* and *replace*.
-- However, as the 'MutableHeap' always represents a heap with its root (minimum value)
-- extracted, *extract-min* is "fused" to other operations.
module KMerge.Heap (
diff --git a/src/Database/LSMTree/Internal/BlobRef.hs b/src/Database/LSMTree/Internal/BlobRef.hs
index 1520ec508..fa8ce525d 100644
--- a/src/Database/LSMTree/Internal/BlobRef.hs
+++ b/src/Database/LSMTree/Internal/BlobRef.hs
@@ -81,7 +81,7 @@ data StrongBlobRef m h = StrongBlobRef {
-- | Convert a 'RawBlobRef' to a 'WeakBlobRef'.
rawToWeakBlobRef :: RawBlobRef m h -> WeakBlobRef m h
rawToWeakBlobRef RawBlobRef {rawBlobRefFile, rawBlobRefSpan} =
- -- This doesn't need to really do anything, becuase the raw version
+ -- This doesn't need to really do anything, because the raw version
-- does not maintain an independent ref count, and the weak one does
-- not either.
WeakBlobRef {
diff --git a/src/Database/LSMTree/Internal/CRC32C.hs b/src/Database/LSMTree/Internal/CRC32C.hs
index 5bd62ee94..995fa6656 100644
--- a/src/Database/LSMTree/Internal/CRC32C.hs
+++ b/src/Database/LSMTree/Internal/CRC32C.hs
@@ -11,7 +11,7 @@
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE UnboxedTuples #-}
--- | Functionalty related to CRC-32C (Castagnoli) checksums:
+-- | Functionality related to CRC-32C (Castagnoli) checksums:
--
-- * Support for calculating checksums while incrementally writing files.
-- * Support for verifying checksums of files.
diff --git a/src/Database/LSMTree/Internal/Index/CompactAcc.hs b/src/Database/LSMTree/Internal/Index/CompactAcc.hs
index fa76554c0..53e81d43a 100644
--- a/src/Database/LSMTree/Internal/Index/CompactAcc.hs
+++ b/src/Database/LSMTree/Internal/Index/CompactAcc.hs
@@ -105,7 +105,7 @@ new maxcsize = IndexCompactAcc
<*> newSTRef SNothing
<*> newSTRef SNothing
--- | We explictly pin the byte arrays, since that allows for more efficient
+-- | We explicitly pin the byte arrays, since that allows for more efficient
-- serialisation, as the definition of 'isByteArrayPinned' changed in GHC 9.6,
-- see .
--
diff --git a/src/Database/LSMTree/Internal/Lookup.hs b/src/Database/LSMTree/Internal/Lookup.hs
index eaab22597..188c51aeb 100644
--- a/src/Database/LSMTree/Internal/Lookup.hs
+++ b/src/Database/LSMTree/Internal/Lookup.hs
@@ -329,7 +329,7 @@ intraPageLookupsOn !resolveV !acc0 !rs !ks !rkixs !ioops !ioress =
V.unsafeInsertWithMStrict res (combine resolveV) kix e'
loop res (ioopix + 1)
- -- Check that the IOOp was performed succesfully, and that it wrote/read
+ -- Check that the IOOp was performed successfully, and that it wrote/read
-- exactly as many bytes as we expected. If not, then the buffer won't
-- contain the correct number of disk-page bytes, so we throw an exception.
checkIOResult :: IOOp (PrimState m) h -> IOResult -> m ()
diff --git a/src/Database/LSMTree/Internal/MergeSchedule.hs b/src/Database/LSMTree/Internal/MergeSchedule.hs
index e5ce5f9b7..b477a438e 100644
--- a/src/Database/LSMTree/Internal/MergeSchedule.hs
+++ b/src/Database/LSMTree/Internal/MergeSchedule.hs
@@ -175,7 +175,7 @@ releaseTableContent reg (TableContent _wb wbb levels cache ul) = do
Levels cache
-------------------------------------------------------------------------------}
--- | Flattend cache of the runs that referenced by a table.
+-- | Flattened cache of the runs that referenced by a table.
--
-- This cache includes a vector of runs, but also vectors of the runs broken
-- down into components, like bloom filters, fence pointer indexes and file
diff --git a/src/Database/LSMTree/Internal/MergingRun.hs b/src/Database/LSMTree/Internal/MergingRun.hs
index 6aa9d4f2f..2fad1877d 100644
--- a/src/Database/LSMTree/Internal/MergingRun.hs
+++ b/src/Database/LSMTree/Internal/MergingRun.hs
@@ -1024,5 +1024,5 @@ expectCompleted (DeRef MergingRun {..}) = do
CompletedMerge r -> dupRef r -- return a fresh reference to the run
OngoingMerge{} -> do
-- If the algorithm finds an ongoing merge here, then it is a bug in
- -- our merge sceduling algorithm. As such, we throw a pure error.
+ -- our merge scheduling algorithm. As such, we throw a pure error.
error "expectCompleted: expected a completed merge, but found an ongoing merge"
diff --git a/src/Database/LSMTree/Internal/Paths.hs b/src/Database/LSMTree/Internal/Paths.hs
index d5cb74abe..d4c6a43e1 100644
--- a/src/Database/LSMTree/Internal/Paths.hs
+++ b/src/Database/LSMTree/Internal/Paths.hs
@@ -96,7 +96,7 @@ newtype SnapshotName = SnapshotName FilePath
instance Show SnapshotName where
showsPrec d (SnapshotName p) = showsPrec d p
--- | The given string must satsify 'isValidSnapshotName'.
+-- | The given string must satisfy 'isValidSnapshotName'.
-- Otherwise, 'fromString' throws an 'InvalidSnapshotNameError'.
instance IsString SnapshotName where
fromString :: String -> SnapshotName
@@ -163,7 +163,7 @@ isValidSnapshotName str =
-- | Create snapshot name.
--
--- The given string must satsify 'isValidSnapshotName'.
+-- The given string must satisfy 'isValidSnapshotName'.
--
-- Throws the following exceptions:
--
@@ -304,7 +304,7 @@ newtype ForIndex a = ForIndex {unForIndex :: a}
ForRunFiles abstraction
-------------------------------------------------------------------------------}
--- | Stores someting for each run file (except the checksums file), allowing to
+-- | Stores something for each run file (except the checksums file), allowing to
-- easily do something for all of them without mixing them up.
data ForRunFiles a = ForRunFiles {
forRunKOps :: !(ForKOps a)
diff --git a/src/Database/LSMTree/Internal/RunAcc.hs b/src/Database/LSMTree/Internal/RunAcc.hs
index 5cce81cca..94cf1e9e3 100644
--- a/src/Database/LSMTree/Internal/RunAcc.hs
+++ b/src/Database/LSMTree/Internal/RunAcc.hs
@@ -1,7 +1,7 @@
{-# LANGUAGE RecordWildCards #-}
{-# OPTIONS_HADDOCK not-home #-}
--- | Incremental (in-memory portion of) run consruction
+-- | Incremental (in-memory portion of) run construction
--
module Database.LSMTree.Internal.RunAcc (
RunAcc (..)
diff --git a/src/Database/LSMTree/Internal/Types.hs b/src/Database/LSMTree/Internal/Types.hs
index 3190f5c89..4beeff594 100644
--- a/src/Database/LSMTree/Internal/Types.hs
+++ b/src/Database/LSMTree/Internal/Types.hs
@@ -182,7 +182,7 @@ resolveValidOutput (v1 :: v) (v2 :: v) =
{- |
Wrapper that provides an instance of 'ResolveValue' via the 'Semigroup'
-instance of the underyling type.
+instance of the underlying type.
prop> resolve (ResolveViaSemigroup v1) (ResolveViaSemigroup v2) = ResolveViaSemigroup (v1 <> v2)
-}
diff --git a/src/Database/LSMTree/Internal/Unsafe.hs b/src/Database/LSMTree/Internal/Unsafe.hs
index f734ac30e..d1e87760f 100644
--- a/src/Database/LSMTree/Internal/Unsafe.hs
+++ b/src/Database/LSMTree/Internal/Unsafe.hs
@@ -1606,7 +1606,7 @@ tableContentToMergingTree seshEnv conf
-- any pre-existing union in the input table:
unionmt = case tableUnionLevel of
NoUnion -> Nothing
- Union mt _ -> Just mt -- we could re-use the cache, but it
+ Union mt _ -> Just mt -- we could reuse the cache, but it
-- would complicate things
in newPendingLevelMerge runs unionmt
where
diff --git a/src/Database/LSMTree/Simple.hs b/src/Database/LSMTree/Simple.hs
index 2eb24d8cd..3d5c423e8 100644
--- a/src/Database/LSMTree/Simple.hs
+++ b/src/Database/LSMTree/Simple.hs
@@ -243,7 +243,7 @@ Just (Value "Hello")
--------------------------------------------------------------------------------
{- $resource_management
-This package uses explicit resource mangagement. The 'Session', 'Table', and 'Cursor'
+This package uses explicit resource management. The 'Session', 'Table', and 'Cursor'
handles hold open resources, such as file handles, which must be explicitly released.
Every operation that allocates a resource is paired with another operation to releases
that resource. For each pair of allocate and release operations there is a bracketed
diff --git a/test/Database/LSMTree/Class/Common.hs b/test/Database/LSMTree/Class/Common.hs
index bb0ca2d45..747e9a7ae 100644
--- a/test/Database/LSMTree/Class/Common.hs
+++ b/test/Database/LSMTree/Class/Common.hs
@@ -27,7 +27,7 @@ import System.FS.BlockIO.API (HasBlockIO)
-- | Constraints for keys, values, and blobs
type C k v b = (CK k, CV v, CB b)
--- | Constaints for keys
+-- | Constraints for keys
type CK k = (C_ k, SerialiseKey k)
-- | Constraints for values
diff --git a/test/Database/LSMTree/Model/Session.hs b/test/Database/LSMTree/Model/Session.hs
index 1ec35d1f5..7aa38c9e5 100644
--- a/test/Database/LSMTree/Model/Session.hs
+++ b/test/Database/LSMTree/Model/Session.hs
@@ -664,7 +664,7 @@ listSnapshots ::
listSnapshots = gets (Map.keys . snapshots)
{-------------------------------------------------------------------------------
- Mutiple writable tables
+ Multiple writable tables
-------------------------------------------------------------------------------}
duplicate ::
diff --git a/test/Database/LSMTree/Model/Table.hs b/test/Database/LSMTree/Model/Table.hs
index 7ea8a43ea..88fd07759 100644
--- a/test/Database/LSMTree/Model/Table.hs
+++ b/test/Database/LSMTree/Model/Table.hs
@@ -255,7 +255,7 @@ snapshot ::
snapshot = id
{-------------------------------------------------------------------------------
- Mutiple writable tables
+ Multiple writable tables
-------------------------------------------------------------------------------}
duplicate ::
diff --git a/test/Test/Database/LSMTree/Internal/CRC32C.hs b/test/Test/Database/LSMTree/Internal/CRC32C.hs
index 8f19434fa..489be0ef2 100644
--- a/test/Test/Database/LSMTree/Internal/CRC32C.hs
+++ b/test/Test/Database/LSMTree/Internal/CRC32C.hs
@@ -72,7 +72,7 @@ prop_putGet (PartialIOErrors errs) bss =
let expected = CRC32C (Data.Digest.CRC32C.crc32c (BS.concat bss))
return (all (expected==) [crc1, crc2, crc3])
--- TODO: test like prop_putGet but with put curruption, to detect that the
+-- TODO: test like prop_putGet but with put corruption, to detect that the
-- crc doesn't match, to detect the corruption.
prop_writeRead :: PartialIOErrors -> ChecksumsFile -> Bool
diff --git a/test/Test/Database/LSMTree/Internal/Index/Compact.hs b/test/Test/Database/LSMTree/Internal/Index/Compact.hs
index 53729eb0d..1c1aa5a5c 100644
--- a/test/Test/Database/LSMTree/Internal/Index/Compact.hs
+++ b/test/Test/Database/LSMTree/Internal/Index/Compact.hs
@@ -396,7 +396,7 @@ multiPageValuesClash ic
-- triplet of contiguous LTP bits, and a C bit corresponding to the middle
-- of the triplet.
p (cj, ltpi, ltpj, ltpk) =
- -- two multi-page values border eachother
+ -- two multi-page values border each other
unBit ltpi && not (unBit ltpj) && unBit ltpk
-- and they clash
&& unBit cj
diff --git a/test/Test/Database/LSMTree/Internal/RunBuilder.hs b/test/Test/Database/LSMTree/Internal/RunBuilder.hs
index c77d7fb02..5d6d52457 100644
--- a/test/Test/Database/LSMTree/Internal/RunBuilder.hs
+++ b/test/Test/Database/LSMTree/Internal/RunBuilder.hs
@@ -50,7 +50,7 @@ runParams =
runParamIndex = Index.Ordinary
}
--- | 'new' in an existing directory should be succesfull.
+-- | 'new' in an existing directory should be successful.
prop_newInExistingDir :: HasFS IO h -> FS.HasBlockIO IO h -> IO Property
prop_newInExistingDir hfs hbio = do
let runDir = FS.mkFsPath ["a", "b", "c"]
diff --git a/test/Test/Database/LSMTree/StateMachine.hs b/test/Test/Database/LSMTree/StateMachine.hs
index 4f807ed30..f18dae3ea 100644
--- a/test/Test/Database/LSMTree/StateMachine.hs
+++ b/test/Test/Database/LSMTree/StateMachine.hs
@@ -367,7 +367,7 @@ propLockstep_RealImpl_MockFS_IO tr cleanupFlag fsFlag refsFlag =
-- @release_RealImpl_MockFS@ are not run in a masked state and it is not
-- guaranteed that the latter runs if the former succeeded. Therefore, if
-- @runActions@ fails (with exceptions), then not having @bracket@ might lead to
--- more exceptions, which can obfuscate the orginal reason that the property
+-- more exceptions, which can obfuscate the original reason that the property
-- failed. Because of this, if @prop@ fails, it's probably best to also try
-- running the @IO@ version of this property with the failing seed, and compare
-- the counterexamples to see which one is more interesting.
@@ -2251,10 +2251,10 @@ data Stats = Stats {
-- | Names for which snapshots exist
snapshotted :: !(Set R.SnapshotName)
-- === Final tags (per action sequence, across all tables)
- -- | Number of succesful lookups and their results
+ -- | Number of successful lookups and their results
, numLookupsResults :: {-# UNPACK #-} !(Int, Int, Int)
-- (NotFound, Found, FoundWithBlob)
- -- | Number of succesful updates
+ -- | Number of successful updates
, numUpdates :: {-# UNPACK #-} !(Int, Int, Int, Int)
-- (Insert, InsertWithBlob, Delete, Mupsert)
-- | Actions that succeeded
@@ -2262,7 +2262,7 @@ data Stats = Stats {
-- | Actions that failed with an error
, failActions :: [(String, Model.Err)]
-- === Final tags (per action sequence, per table)
- -- | Number of actions per table (succesful or failing)
+ -- | Number of actions per table (successful or failing)
, numActionsPerTable :: !(Map Model.TableID Int)
-- | The state of model tables at the point they were closed. This is used
-- to augment the tables from the final model state (which of course has
@@ -2703,25 +2703,25 @@ data FinalTag =
| NumLookupsFound String
-- | Total number of lookup results that were 'SUT.FoundWithBlob'
| NumLookupsFoundWithBlob String
- -- | Number of 'Class.Insert's succesfully submitted to a table
+ -- | Number of 'Class.Insert's successfully submitted to a table
-- (this includes submissions through both 'Class.updates' and
-- 'Class.inserts')
| NumInserts String
- -- | Number of 'Class.InsertWithBlob's succesfully submitted to a table
+ -- | Number of 'Class.InsertWithBlob's successfully submitted to a table
-- (this includes submissions through both 'Class.updates' and
-- 'Class.inserts')
| NumInsertsWithBlobs String
- -- | Number of 'Class.Delete's succesfully submitted to a table
+ -- | Number of 'Class.Delete's successfully submitted to a table
-- (this includes submissions through both 'Class.updates' and
-- 'Class.deletes')
| NumDeletes String
- -- | Number of 'Class.Mupsert's succesfully submitted to a table
+ -- | Number of 'Class.Mupsert's successfully submitted to a table
-- (this includes submissions through both 'Class.updates' and
-- 'Class.mupserts')
| NumMupserts String
-- | Total number of actions (failing, succeeding, either)
| NumActions String
- -- | Which actions succeded
+ -- | Which actions succeeded
| ActionSuccess String
-- | Which actions failed
| ActionFail String Model.Err
@@ -2860,13 +2860,13 @@ runActionsBracket p cleanupFlag refsFlag init cleanup runner tagger actions =
cleanup' st = do
-- We want to run forgotten reference checks after cleanup, since cleanup
-- itself may lead to forgotten refs. The reference checks have the
- -- crucial side effect of reseting the forgotten refs state. If we don't
+ -- crucial side effect of resetting the forgotten refs state. If we don't
-- do this then the next test run (e.g. during shrinking) will encounter a
-- false/stale forgotten refs exception. But we also have to make sure
-- that if cleanup itself fails, that we still run the reference checks.
-- 'propCleanup' will make sure to catch any exceptions that are thrown by
-- the 'cleanup' action. 'propRefs' will then definitely run afterwards so
- -- that the frogotten reference checks are definitely performed.
+ -- that the forgotten reference checks are definitely performed.
x <- propCleanup cleanupFlag $ cleanup st
y <- propRefs refsFlag
pure (x QC..&&. y)
diff --git a/test/Test/Database/LSMTree/StateMachine/DL.hs b/test/Test/Database/LSMTree/StateMachine/DL.hs
index 3d4b2721e..49b8495bd 100644
--- a/test/Test/Database/LSMTree/StateMachine/DL.hs
+++ b/test/Test/Database/LSMTree/StateMachine/DL.hs
@@ -178,7 +178,7 @@ dl_noSwallowExceptions = do
-- generates an arbitrary probability for each stream, which should generate a
-- larger variety of 'Errors' structures.
--
--- TODO: upstream to @fs-sim@ to replase the default 'genErrors'?
+-- TODO: upstream to @fs-sim@ to replace the default 'genErrors'?
arbitraryErrors :: Gen Errors
arbitraryErrors = do
dumpStateE <- genStream arbitrary
diff --git a/test/Test/Util/FS.hs b/test/Test/Util/FS.hs
index 031fb6ca6..15b030c30 100644
--- a/test/Test/Util/FS.hs
+++ b/test/Test/Util/FS.hs
@@ -286,7 +286,7 @@ approximateEqStream (UnsafeStream infoXs xs) (UnsafeStream infoYs ys) =
data DirEntry a = Directory a | File a
deriving stock (Show, Eq, Ord, Functor)
--- | List all files and directories in the given directory and recusively in all
+-- | List all files and directories in the given directory and recursively in all
-- sub-directories.
listDirectoryRecursive ::
Monad m