core driver

This commit is contained in:
crumbtoo
2024-02-01 15:24:16 -07:00
parent ff5a5af9bc
commit 77f2f900d8
6 changed files with 42 additions and 19 deletions

View File

@@ -3,12 +3,15 @@ module CoreDriver
)
where
--------------------------------------------------------------------------------
import Compiler.RLPC
import Control.Monad
import Core.Lex
import Core.Parse
import GM
--------------------------------------------------------------------------------
driver :: RLPCIO ()
driver = undefined
parseProg :: RLPCOptions
-> Text
-> (Maybe Program', [MsgEnvelope RlpcError])
parseProg o = lexCoreR >=> parseCoreProgR
driver = forFiles_ $ \f ->
withSource f (lexCoreR >=> parseCoreProgR >=> evalProgR)