Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/Data/Vector/Algorithms/Common.hs
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,7 @@ resizeVector !src !sz = do
pure dst
{-# inline resizeVector #-}

-- Used inernally in resizeVector: copy a vector from a larger to
-- Used internally in resizeVector: copy a vector from a larger to
-- smaller vector. Should not be used if the source vector
-- is smaller than the target vector.
copyToSmaller
Expand Down
2 changes: 1 addition & 1 deletion src/Data/Vector/Algorithms/Search.hs
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,7 @@ binarySearchRByBounds cmp vec e = binarySearchPBounds p vec
where p e' = case cmp e' e of GT -> True ; _ -> False
{-# INLINE binarySearchRByBounds #-}

-- | Given a predicate that is guaraneteed to be monotone on the given vector,
-- | Given a predicate that is guaranteed to be monotone on the given vector,
-- finds the first index at which the predicate returns True, or the length of
-- the array if the predicate is false for the entire array.
binarySearchP :: (PrimMonad m, MVector v e) => (e -> Bool) -> v (PrimState m) e -> m Int
Expand Down