\begin{small}\begin{verbatim} (* TML Tree: *) infiniteCost :Int (* Value representing infinite evaluation cost for a TML tree *) defaultInfo :Int (* Value representing usefule default information for the optimizer *) Let Rec EvalFn = All(:T)T (* a meta-evaluation function *) and CostFn = All(:T)Int (* cost estimate for a call *) and T = Tuple (* a TML node *) case primitive with (* a primitive procedure *) name :String (* user name, printing only *) info :PrimitiveInfo (* attributes useful for the optimizer *) eval :EvalFn (* a meta-evaluation function *) cost :CostFn (* cost estimate *) end (* Note that the functional position of apply nodes (node!apply.fn) is the only place where primitive nodes may appear. I.e., they cannot be passed around as values. *) case variable with name :String fCont :Bool (* true iff this variable names a continuation *) end case literal with value :Literal end case readRef with (* variable reference *) variable :T end case lambda with variables :list.T(T) (* linked list of formal paramaters *) body :T (* must be an appliation *) end case apply with fn :T (* primitive, readRef, literal or lambda node *) args :list.T(T) (* linked list of actual parameters *) end end (* T *) and Literal = Tuple case nil with end case literals with value :Array(Literal) end case tml with value :T end case bool with value :Bool end case char with value :Char end case int with value :Int end case real with value :Real end case string with value :String end case byteArray with value :OID end end \end{verbatim}\end{small}