jon.recoil.org

Module Function.Emitter

type funcdef = t
type t = {
  1. ident_gen : Ident.Gen.t;
  2. funcdef : funcdef;
}
val create : name:string -> args:Type.t list -> res:Type.Or_void.t -> cc:Calling_conventions.t -> attrs:Fn_attr.t list -> dbg:Debuginfo.t -> private_:bool -> t
val get_fun : t -> funcdef
val get_args_as_values : t -> Value.t list
val get_res_type : t -> Type.Or_void.t
val get_fun_ident : t -> Ident.t
val ins : ?comment:string -> ?res_ident:Ident.t -> t -> Instruction.op -> Value.t
val ins_no_res : ?comment:string -> t -> Instruction.op -> unit
val comment : t -> string -> unit
val label_def : t -> Ident.t -> unit