cleanup temporaries

This commit is contained in:
eagletmt 2012-02-14 19:14:21 +09:00
parent 1b1245577e
commit fab993acfa

View File

@ -12,7 +12,9 @@ import Types
----------------------------------------------------------------
withGHC :: (MonadPlus m) => Ghc (m a) -> IO (m a)
withGHC body = ghandle ignore $ runGhc (Just libdir) body
withGHC body = ghandle ignore $ runGhc (Just libdir) $ do
dflags <- getSessionDynFlags
defaultCleanupHandler dflags body
where
ignore :: (MonadPlus m) => SomeException -> IO (m a)
ignore _ = return mzero