Skip to content

Commit 58d98a7

Browse files
author
Jeremy Shaw
committed
fix compiler warning regarding Prelude.catch -> Control.Exception.catch
1 parent 0c1cb11 commit 58d98a7

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

src/System/Plugins/Utils.hs

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
{-# LANGUAGE CPP #-}
1+
{-# LANGUAGE CPP, ScopedTypeVariables #-}
22
--
33
-- Copyright (C) 2004 Don Stewart - http://www.cse.unsw.edu.au/~dons
44
--
@@ -63,8 +63,10 @@ import System.Plugins.Env ( isLoaded )
6363
import System.Plugins.Consts ( objSuf, hiSuf, tmpDir )
6464
-- import qualified System.MkTemp ( mkstemps )
6565

66+
import Control.Exception (IOException, catch)
6667
import Data.Char
6768
import Data.List
69+
import Prelude hiding (catch)
6870

6971
import System.IO
7072
import System.Environment ( getEnv )
@@ -119,7 +121,7 @@ foreign import ccall unsafe "mkstemps" c_mkstemps :: CString -> CInt -> IO Fd
119121
-- bit like the mktemp shell utility
120122
--
121123
mkTemp :: IO (String,Handle)
122-
mkTemp = do tmpd <- catch (getEnv "TMPDIR") (\_ -> return tmpDir)
124+
mkTemp = do tmpd <- catch (getEnv "TMPDIR") (\ (_ :: IOException) -> return tmpDir)
123125
mkTempIn tmpd
124126

125127
mkTempIn :: String -> IO (String, Handle)

0 commit comments

Comments
 (0)