htcc-0.0.0.1: The full scratch implementation of tiny C compiler (x86_64)
Copyright(c) roki 2019
LicenseMIT
Maintainerfalgon53@yahoo.co.jp
Stabilityexperimental
PortabilityPOSIX
Safe HaskellNone
LanguageHaskell2010

Htcc.Asm.Generate

Contents

Description

The executable module for compilation

Synopsis

Documentation

type InputCCode = Text Source #

input string, C source code

Generator

casm' :: (Integral e, Show e, Integral i, IsOperand i, UnaryInstruction i, BinaryInstruction i) => ASTs i -> GlobalVars i -> Literals i -> Asm AsmCodeCtx e () Source #

Executor that receives information about the constructed AST, global variables, and literals and composes assembly code

buildAST :: (Integral i, Read i, Show i, Bits i) => InputCCode -> ASTResult i Source #

Build AST from string of C source code

execAST :: (Integral i, Read i, Show i, Bits i) => Bool -> FilePath -> InputCCode -> IO (Maybe (ASTs i, GlobalVars i, Literals i)) Source #

Print warning or error message if building AST from string of C source code has some problems