aboutsummaryrefslogtreecommitdiff
path: root/app/Main.hs
diff options
context:
space:
mode:
authorJuan J. Martinez <jjm@usebox.net>2022-09-10 19:36:45 +0100
committerJuan J. Martinez <jjm@usebox.net>2022-09-10 19:36:45 +0100
commitc72455c9f4203ab7b9c617f26ffa7e5fdabf2d5f (patch)
treed3beadb7148c78123a777df9c82209882e7a0096 /app/Main.hs
parent808f960c6aa800b0d3dcde897959a8e26303ef7d (diff)
downloadmicro-lang-hs-c72455c9f4203ab7b9c617f26ffa7e5fdabf2d5f.tar.gz
micro-lang-hs-c72455c9f4203ab7b9c617f26ffa7e5fdabf2d5f.zip
Revisited parser interface
Diffstat (limited to 'app/Main.hs')
-rw-r--r--app/Main.hs5
1 files changed, 2 insertions, 3 deletions
diff --git a/app/Main.hs b/app/Main.hs
index 9cf5d75..fb3c132 100644
--- a/app/Main.hs
+++ b/app/Main.hs
@@ -6,8 +6,7 @@ import qualified Data.Map as Map
import Data.Maybe (fromMaybe)
import Micro.Compiler
import Micro.Error (showErrorList, showParserError)
-import Micro.Lexer (scan)
-import Micro.Parser (parse, parseFromFile)
+import Micro.Parser
import System.Console.GetOpt
import System.Environment (getProgName)
import System.Environment.Blank (getArgs)
@@ -64,7 +63,7 @@ usage progName errs
compileFile :: String -> Bool -> IO ()
compileFile filename onlyParse = do
- res <- parseFromFile (scan parse) filename
+ res <- parseFromFile filename
case res of
Left err -> hPutStrLn stderr (showParserError err) >> exitFailure
Right ast -> do