Merge pull request #585 from david-christiansen/error-reflection
Properly show errors in batch compile mode
commitc0cda70810ce89842f6c4ee0e3f9e4fe50e8a3cc
authorEdwin Brady <edwin.brady@gmail.com>
dateSun 3 Nov 2013, 09:40 (13 years ago)
parentfe3354b7c255e9
src/Idris/REPL.hs+2−1
@@ -1125,7 +1125,8 @@ idrisMain opts =
11251125 ok <- noErrors
11261126 when ok $ case output of
11271127 [] -> return ()
1128− (o:_) -> process stdout "" (Compile cgn o)
1128+ (o:_) -> idrisCatch (process stdout "" (Compile cgn o))
1129+ (\e -> do ist <- getIState ; iputStrLn $ pshow ist e)
11291130 case script of
11301131 Nothing -> return ()
11311132 Just expr -> execScript expr