ligo/tools/lsp/squirrel/app/Main.hs

19 lines
315 B
Haskell
Raw Normal View History

2020-04-30 14:39:51 +04:00
import Data.Foldable (for_)
2020-04-30 14:39:51 +04:00
import ParseTree
import Parser
import AST
import PrettyPrint
2020-04-30 14:39:51 +04:00
import System.Environment
main :: IO ()
main = do
[fin] <- getArgs
toParseTree fin >>= print
(res, errs) <- runParser contract fin
print (pp res)
putStrLn ""
putStrLn "Errors:"
for_ errs (print . nest 2 . pp)