Print generated llvm
parent
37dcd45432
commit
c0e77d22cf
|
@ -1,4 +1,4 @@
|
|||
module LLVMGen.Expression () where
|
||||
module LLVMGen.Expression (getLLVM) where
|
||||
|
||||
import qualified Objects.Expression as Expr
|
||||
|
||||
|
@ -47,5 +47,5 @@ toLLVM modul = withContext $ \ctx -> do
|
|||
llvm <- withModuleFromAST ctx modul moduleLLVMAssembly
|
||||
BS.putStrLn llvm
|
||||
|
||||
main :: IO ()
|
||||
main = toLLVM module_
|
||||
getLLVM :: IO ()
|
||||
getLLVM = toLLVM module_
|
|
@ -6,6 +6,7 @@ import Eval.Expression
|
|||
import Objects.Expression
|
||||
import Parser.Expression
|
||||
import System.Environment
|
||||
import LLVMGen.Expression
|
||||
import System.IO
|
||||
import Text.Megaparsec
|
||||
|
||||
|
@ -20,3 +21,4 @@ main = do
|
|||
contents <- readFile fileName
|
||||
let result = getResult contents
|
||||
print result
|
||||
getLLVM
|
||||
|
|
Reference in New Issue