error reporting
This commit is contained in:
parent
b370f52f88
commit
1910795ddf
1 changed files with 3 additions and 1 deletions
|
@ -114,7 +114,9 @@ getOutput cmd params env = do
|
||||||
processTranscript' cmd params env Nothing
|
processTranscript' cmd params env Nothing
|
||||||
|
|
||||||
runParser' :: Parser a -> String -> a
|
runParser' :: Parser a -> String -> a
|
||||||
runParser' p s = either (error . show) id (parse p "" s)
|
runParser' p s = either failedparse id (parse p "" s)
|
||||||
|
where
|
||||||
|
failedparse e = error $ (show e) ++ "\nInput:\n" ++ s
|
||||||
|
|
||||||
atFile :: FilePath -> String
|
atFile :: FilePath -> String
|
||||||
atFile f = '@':f
|
atFile f = '@':f
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue