mirror of
https://github.com/joshuaclayton/unused.git
synced 2024-09-11 04:45:28 +03:00
Extract ioOps calculation
This commit is contained in:
parent
2ec73ac3b3
commit
bbb178f7d5
@ -23,4 +23,6 @@ progressWithIndicator :: (a -> IO [b]) -> ProgressIndicator -> [a] -> IO [b]
|
||||
progressWithIndicator f i terms = do
|
||||
printPrefix i
|
||||
indicator <- start i $ length terms
|
||||
concat <$> mapM (\t -> f t <* increment indicator) terms <* stop indicator
|
||||
concat <$> sequence (ioOps indicator) <* stop indicator
|
||||
where
|
||||
ioOps i' = map (\t -> f t <* increment i') terms
|
||||
|
Loading…
Reference in New Issue
Block a user