definition module Sil.Syntax from Data.Maybe import :: Maybe :: Program = { p_funs :: [Function] } :: Function = { f_type :: Type , f_name :: Name , f_args :: [Arg] , f_code :: CodeBlock } :: CodeBlock = { cb_init :: [Initialisation] , cb_content :: [Statement] } :: Arg = { arg_type :: Type , arg_name :: Name } :: Initialisation = { init_type :: Type , init_name :: Name } :: Statement = Declaration Name Application | Application Application | Return (Maybe Application) | If Application CodeBlock (Maybe CodeBlock) | While Application CodeBlock :: Application = Name Name | Literal Literal | App Name [Application] :: Type = TBool | TInt | TVoid :: Literal = BLit Bool | ILit Int :: Name :== String