Module Synext.Make_precedences

Parameters

module S : sig ... end

Signature

include Support.Imperative_state.IMPERATIVE_STATE with type state = S.state
type state = S.state
val traverse_tuple2 : state -> (state -> 'a1 -> 'b1) -> (state -> 'a2 -> 'b2) -> ('a1 * 'a2) -> 'b1 * 'b2
val traverse_tuple3 : state -> (state -> 'a1 -> 'b1) -> (state -> 'a2 -> 'b2) -> (state -> 'a3 -> 'b3) -> ('a1 * 'a2 * 'a3) -> 'b1 * 'b2 * 'b3
val traverse_list : state -> (state -> 'a -> 'b) -> 'a Support.List.t -> 'b Support.List.t

traverse_list state f [x1; x2; ...; xn] is [y1; y2; ...; yn] where yi = f state xi, and y1, y2, ..., yn are computed in order, meaning that y1 is computed first, then y2, etc.

val traverse_list1 : state -> (state -> 'a -> 'b) -> 'a Support.List1.t -> 'b Support.List1.t
val traverse_list2 : state -> (state -> 'a -> 'b) -> 'a Support.List2.t -> 'b Support.List2.t
val iter_list : state -> (state -> 'a -> Stdlib.Unit.t) -> 'a Support.List.t -> Stdlib.Unit.t

iter_list state f [x1; x2; ...; xn] is f state x1; f state x2; ...; f state xn.

val iter_list1 : state -> (state -> 'a -> Stdlib.Unit.t) -> 'a Support.List1.t -> Stdlib.Unit.t
val iter_list2 : state -> (state -> 'a -> Stdlib.Unit.t) -> 'a Support.List2.t -> Stdlib.Unit.t
val traverse_reverse_list : state -> (state -> 'a -> 'b) -> 'a Support.List.t -> 'b Support.List.t

traverse_reverse_list state f [x1; x2; ...; xn] is [y1; y2; ...; yn] where yi = f state xi, and y1, y2, ..., yn are computed in reverse order, meaning that yn is computed first, then y(n-1), etc.

val traverse_reverse_list1 : state -> (state -> 'a -> 'b) -> 'a Support.List1.t -> 'b Support.List1.t
val traverse_reverse_list2 : state -> (state -> 'a -> 'b) -> 'a Support.List2.t -> 'b Support.List2.t
val iter_rev_list : state -> (state -> 'a -> Stdlib.Unit.t) -> 'a Support.List.t -> Stdlib.Unit.t

iter_rev_list state f [x1; x2; ...; xn] is f state xn; f state x(n-1); ...; f state x1.

val iter_rev_list1 : state -> (state -> 'a -> Stdlib.Unit.t) -> 'a Support.List1.t -> Stdlib.Unit.t
val iter_rev_list2 : state -> (state -> 'a -> Stdlib.Unit.t) -> 'a Support.List2.t -> Stdlib.Unit.t
val traverse_option : state -> (state -> 'a -> 'b) -> 'a Support.Option.t -> 'b Support.Option.t
val iter_option : state -> (state -> 'a -> Stdlib.Unit.t) -> 'a Support.Option.t -> Stdlib.Unit.t
val seq_list : state -> (state -> 'a) Support.List.t -> 'a Support.List.t
val seq_list1 : state -> (state -> 'a) Support.List1.t -> 'a Support.List1.t
val iter_seq : state -> (state -> Stdlib.Unit.t) Support.List.t -> Stdlib.Unit.t

Precedence of LF Syntax

module Lf_precedence : sig ... end
val precedence_of_lf_kind : state -> lf_kind -> Lf_precedence.precedence
val precedence_of_lf_typ : state -> lf_typ -> Lf_precedence.precedence
val precedence_of_lf_term : state -> lf_term -> Lf_precedence.precedence

Precedence of Contextual LF Syntax

module Clf_precedence : sig ... end
val precedence_of_clf_typ : state -> clf_typ -> Clf_precedence.precedence
val precedence_of_clf_term : state -> clf_term -> Clf_precedence.precedence
val precedence_of_clf_term_pattern : state -> clf_term_pattern -> Clf_precedence.precedence

Precedence of Meta-Level Syntax

module Schema_precedence : sig ... end
val precedence_of_schema : state -> schema -> Schema_precedence.precedence

Precedence of Computation-Level Syntax

module Comp_sort_precedence : sig ... end
val precedence_of_comp_kind : state -> comp_kind -> Comp_sort_precedence.precedence
val precedence_of_comp_typ : state -> comp_typ -> Comp_sort_precedence.precedence
module Comp_expression_precedence : sig ... end
val precedence_of_comp_expression : state -> comp_expression -> Comp_expression_precedence.precedence
module Comp_pattern_precedence : sig ... end
val precedence_of_comp_pattern : state -> comp_pattern -> Comp_pattern_precedence.precedence