[commit: ghc] wip/nfs-locking: Update the docs for chunksOfSize (916d5a9)
git at git.haskell.org
git at git.haskell.org
Fri Oct 27 00:07:32 UTC 2017
Repository : ssh://git@git.haskell.org/ghc
On branch : wip/nfs-locking
Link : http://ghc.haskell.org/trac/ghc/changeset/916d5a93c7dba53c730e49e00a0c0656e75e602b/ghc
>---------------------------------------------------------------
commit 916d5a93c7dba53c730e49e00a0c0656e75e602b
Author: Neil Mitchell <ndmitchell at gmail.com>
Date: Mon Jan 11 11:14:12 2016 +0000
Update the docs for chunksOfSize
>---------------------------------------------------------------
916d5a93c7dba53c730e49e00a0c0656e75e602b
src/Settings/Builders/Ar.hs | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/Settings/Builders/Ar.hs b/src/Settings/Builders/Ar.hs
index 8cf175f..59b70b8 100644
--- a/src/Settings/Builders/Ar.hs
+++ b/src/Settings/Builders/Ar.hs
@@ -46,7 +46,7 @@ useSuccessiveInvocations path flagArgs fileArgs = do
unit . cmd [path] $ flagArgs ++ argsChunk
-- | @chunksOfSize size strings@ splits a given list of strings into chunks not
--- exceeding the given @size at .
+-- exceeding the given @size at . If that is impossible, it uses singleton chunks.
chunksOfSize :: Int -> [String] -> [[String]]
chunksOfSize n = repeatedly f
where f xs = splitAt (max 1 $ length $ takeWhile (<= n) $ scanl1 (+) $ map length xs) xs
More information about the ghc-commits
mailing list