Add a -parse option for future distinguishment.
This commit is contained in:
@@ -28,6 +28,10 @@ main = do
|
|||||||
Right ress -> do
|
Right ress -> do
|
||||||
mapM_ putStrLn ress
|
mapM_ putStrLn ress
|
||||||
putStrLn "Successful lex."
|
putStrLn "Successful lex."
|
||||||
|
["-parse",path] -> do
|
||||||
|
ast <- loadModule path
|
||||||
|
putStrLn "Successful parse!"
|
||||||
|
putStrLn (show ast)
|
||||||
_ -> fail "Unacceptable arguments."
|
_ -> fail "Unacceptable arguments."
|
||||||
|
|
||||||
pullTokens :: Parser [String]
|
pullTokens :: Parser [String]
|
||||||
|
|||||||
Reference in New Issue
Block a user