summaryrefslogtreecommitdiff
path: root/utils/hpc
diff options
context:
space:
mode:
authorIan Lynagh <igloo@earth.li>2010-12-18 21:33:50 +0000
committerIan Lynagh <igloo@earth.li>2010-12-18 21:33:50 +0000
commitb00e3a6c0a82a8af3238d677f798d812cd7fd49f (patch)
tree221590400c93958028a5538f2767b6c2a2ab158c /utils/hpc
parent50769d7532f90b0ec1f1759a56d478cf2926a0ff (diff)
downloadhaskell-b00e3a6c0a82a8af3238d677f798d812cd7fd49f.tar.gz
Replace uses of the old catch function with the new one
Diffstat (limited to 'utils/hpc')
-rw-r--r--utils/hpc/HpcUtils.hs12
1 files changed, 6 insertions, 6 deletions
diff --git a/utils/hpc/HpcUtils.hs b/utils/hpc/HpcUtils.hs
index 397a041965..5655f837f3 100644
--- a/utils/hpc/HpcUtils.hs
+++ b/utils/hpc/HpcUtils.hs
@@ -23,9 +23,9 @@ readFileFromPath :: (String -> IO String) -> String -> [String] -> IO String
readFileFromPath _ filename@('/':_) _ = readFile filename
readFileFromPath err filename path0 = readTheFile path0
where
- readTheFile [] = err $ "could not find " ++ show filename
- ++ " in path " ++ show path0
- readTheFile (dir:dirs) =
- catch (do str <- readFile (dir ++ "/" ++ filename)
- return str)
- (\ _ -> readTheFile dirs)
+ readTheFile [] = err $ "could not find " ++ show filename
+ ++ " in path " ++ show path0
+ readTheFile (dir:dirs) =
+ catchIO (do str <- readFile (dir ++ "/" ++ filename)
+ return str)
+ (\ _ -> readTheFile dirs)