[commit: haddock] ghc-7.4: tests/html-tests/copy.hs: Use mapM_ instead of mapM (87a287f)
David Waern
waern at galois.com
Sat Feb 4 13:38:47 CET 2012
Repository : ssh://darcs.haskell.org//srv/darcs/haddock
On branch : ghc-7.4
http://hackage.haskell.org/trac/ghc/changeset/87a287f5d6999ef1e1228eabbdfd3268a541fe46
>---------------------------------------------------------------
commit 87a287f5d6999ef1e1228eabbdfd3268a541fe46
Author: Simon Hengel <sol at typeful.net>
Date: Thu Jan 12 16:53:36 2012 +0100
tests/html-tests/copy.hs: Use mapM_ instead of mapM
So we do net get a list of () on stdout when running with runhaskell.
>---------------------------------------------------------------
tests/html-tests/copy.hs | 5 +++--
1 files changed, 3 insertions(+), 2 deletions(-)
diff --git a/tests/html-tests/copy.hs b/tests/html-tests/copy.hs
index fe1e542..188bfd3 100644
--- a/tests/html-tests/copy.hs
+++ b/tests/html-tests/copy.hs
@@ -7,15 +7,16 @@ import Data.List
import Control.Monad
+main :: IO ()
main = do
args <- getArgs
dir <- getCurrentDirectory
contents <- getDirectoryContents (dir </> "output")
if not $ null args
then
- mapM copy [ "output" </> file | file <- contents, ".html" `isSuffixOf` file, takeBaseName file `elem` args ]
+ mapM_ copy [ "output" </> file | file <- contents, ".html" `isSuffixOf` file, takeBaseName file `elem` args ]
else
- mapM copy [ "output" </> file | file <- contents, ".html" `isSuffixOf` file ]
+ mapM_ copy [ "output" </> file | file <- contents, ".html" `isSuffixOf` file ]
copy file = do
More information about the Cvs-ghc
mailing list