Module Fang_translate
Translating Tiger to the intermediate representation (IR).
Translation requires:
- An architecture-specific specification of a stack frame (i.e., an implementation of FRAME)
- An interpreter for the IR (i.e., an implementation of IR)
A subsequent compiler phase converts this IR to a much nicer (and shorter!) canonical form.
type 'a fragment
= label * 'a
A fragment is any labelled thing.
val pp_string_fragment : string fragment Fmt.t
Pretty-print (for human consumption) a labeled string constant.
val pp_frame_fragment : box Fmt.t -> (value Pretty.t * frame_ptr) fragment Fmt.t
Pretty-print (for human consumption) a labeled subroutine consisting of pretty-printed IR and the requirements for the frame pointer.
module type TRANSLATE = sig ... end