tools/pas2c/PascalPreprocessor.hs
changeset 10119 7e05a397602f
parent 10113 b26c2772e754
child 10120 b7f632c12784
--- a/tools/pas2c/PascalPreprocessor.hs	Fri Feb 07 10:11:10 2014 +0100
+++ b/tools/pas2c/PascalPreprocessor.hs	Fri Feb 07 14:41:49 2014 +0400
@@ -6,8 +6,7 @@
 import Control.Monad
 import System.IO
 import qualified Data.Map as Map
-import Control.Exception(catch, IOException)
-import Prelude
+import qualified Control.Exception as E
 
 char' :: Char -> ParsecT String u IO ()
 char' = void . char
@@ -80,7 +79,9 @@
         char' '"'
         spaces
         char' '}'
-        f <- liftIO (readFile (inputPath ++ ifn) `catch` (\(_ :: IOException) -> readFile (alternateInputPath ++ ifn) `catch` (\(_ :: IOException) -> error ("File not found: " ++ fn))))
+        f <- liftIO (readFile (inputPath ++ ifn) 
+            `E.catch` (\(_ :: E.IOException) -> readFile (alternateInputPath ++ ifn) 
+            `E.catch` (\(_ :: E.IOException) -> error ("File not found: " ++ fn))))
         c <- getInput
         setInput $ f ++ c
         return ""