(** This module provides folding functions over the constructors of the [Cminor]'s AST. *) (* In [expression_left f e], [f]'s second argument is the list of [expression_left]'s results on [e]'s sub-expressions. The results are computed from left to right following their appearance order in the [Cminor.expression] type. *) val expression_left : (Cminor.expression -> 'a list -> 'a) -> Cminor.expression -> 'a (* In [statement_left f_expr f_stmt stmt], [f_stmt]'s second argument is the list of [expression_left f_expr]'s results on [stmt]'s sub-expressions, and [f_stmt]'s third argument is the list of [statement_left]'s results on [stmt]'s sub-statements. The results are computed from left to right following their appearance order in the [Cminor.statement] type. *) val statement_left : (Cminor.expression -> 'a list -> 'a) -> (Cminor.statement -> 'a list -> 'b list -> 'b) -> Cminor.statement -> 'b (* In [expression_right f e], [f]'s second argument is the list of [expression_right]'s results on [e]'s sub-expressions. The results are computed from right to left following their appearance order in the [Cminor.expression] type. *) val expression_right : ('a list -> Cminor.expression -> 'a) -> Cminor.expression -> 'a (* In [statement_right f_expr f_stmt stmt], [f_stmt]'s second argument is the list of [expression_left f_expr]'s results on [stmt]'s sub-expressions, and [f_stmt]'s third argument is the list of [statement_left]'s results on [stmt]'s sub-statements. The results are computed from right to left following their appearance order in the [Cminor.statement] type. *) val statement_right : ('a list -> Cminor.expression -> 'a) -> ('a list -> 'b list -> Cminor.statement -> 'b) -> Cminor.statement -> 'b