package zelus

  1. Overview
  2. Docs
type kind =
  1. | S
  2. | AS
  3. | A
  4. | C
  5. | AD
  6. | D
  7. | P
type name = string
type qualident = {
  1. qual : name;
  2. id : name;
}
type longname =
  1. | Name of name
  2. | Modname of qualident
type 'a localized = {
  1. desc : 'a;
  2. loc : Zlocation.location;
}
type type_expression = type_expression_desc localized

Types

and type_expression_desc =
  1. | Etypevar of name
  2. | Etypeconstr of longname * type_expression list
  3. | Etypetuple of type_expression list
  4. | Etypevec of type_expression * size
  5. | Etypefun of kind * string option * type_expression * type_expression
and size = size_desc localized
and size_desc =
  1. | Sconst of int
  2. | Sname of longname
  3. | Sop of size_op * size * size
and size_op =
  1. | Splus
  2. | Sminus
type interface = interface_desc localized

Declarations and expressions

and interface_desc =
  1. | Einter_open of name
  2. | Einter_typedecl of name * name list * type_decl
  3. | Einter_constdecl of name * type_expression
and type_decl = type_decl_desc localized
and type_decl_desc =
  1. | Eabstract_type
  2. | Eabbrev of type_expression
  3. | Evariant_type of constr_decl list
  4. | Erecord_type of (name * type_expression) list
and constr_decl = constr_decl_desc localized
and constr_decl_desc =
  1. | Econstr0decl of name
  2. | Econstr1decl of name * type_expression list
and implementation = implementation_desc localized
and implementation_desc =
  1. | Eopen of name
  2. | Etypedecl of name * name list * type_decl
  3. | Econstdecl of name * is_static * exp
  4. | Efundecl of name * funexp
and funexp = {
  1. f_kind : kind;
  2. f_atomic : is_atomic;
  3. f_args : pattern list;
  4. f_body : exp;
  5. f_loc : Zlocation.location;
}
and is_atomic = bool
and is_static = bool
and exp = desc localized
and desc =
  1. | Evar of longname
  2. | Econst of immediate
  3. | Econstr0 of constr
  4. | Econstr1 of constr * exp list
  5. | Elast of name
  6. | Eapp of app * exp * exp list
  7. | Eop of op * exp list
  8. | Etuple of exp list
  9. | Erecord_access of exp * longname
  10. | Erecord of (longname * exp) list
  11. | Erecord_with of exp * (longname * exp) list
  12. | Etypeconstraint of exp * type_expression
  13. | Elet of is_rec * eq list * exp
  14. | Eseq of exp * exp
  15. | Eperiod of period
  16. | Ematch of exp * exp match_handler list
  17. | Epresent of exp present_handler list * exp default option
  18. | Eautomaton of exp state_handler list * state_exp option
  19. | Ereset of exp * exp
  20. | Eblock of eq list block * exp
and is_rec = bool
and app = {
  1. app_inline : bool;
  2. app_statefull : bool;
}
and 'a default =
  1. | Init of 'a
  2. | Default of 'a
and op =
  1. | Efby
  2. | Eunarypre
  3. | Eifthenelse
  4. | Eminusgreater
  5. | Eup
  6. | Einitial
  7. | Edisc
  8. | Etest
  9. | Eaccess
  10. | Eupdate
  11. | Eslice of size * size
  12. | Econcat
  13. | Eatomic
and immediate =
  1. | Eint of int
  2. | Efloat of float
  3. | Ebool of bool
  4. | Echar of char
  5. | Estring of string
  6. | Evoid
and constant =
  1. | Cimmediate of immediate
  2. | Cglobal of longname
and period = {
  1. p_phase : exp option;
  2. p_period : exp;
}
and constr = longname
and pattern = pdesc localized
and pdesc =
  1. | Etuplepat of pattern list
  2. | Evarpat of name
  3. | Ewildpat
  4. | Econstpat of immediate
  5. | Econstr0pat of longname
  6. | Econstr1pat of longname * pattern list
  7. | Ealiaspat of pattern * name
  8. | Eorpat of pattern * pattern
  9. | Erecordpat of (longname * pattern) list
  10. | Etypeconstraintpat of pattern * type_expression
and eq = eqdesc localized
and eqdesc =
  1. | EQeq of pattern * exp
  2. | EQder of name * exp * exp option * exp present_handler list
  3. | EQinit of name * exp
  4. | EQnext of name * exp * exp option
  5. | EQemit of name * exp option
  6. | EQpluseq of name * exp
  7. | EQautomaton of eq list state_handler list * state_exp option
  8. | EQpresent of eq list block present_handler list * eq list block option
  9. | EQmatch of exp * eq list block match_handler list
  10. | EQifthenelse of exp * eq list block * eq list block option
  11. | EQreset of eq list * exp
  12. | EQand of eq list
  13. | EQbefore of eq list
  14. | EQblock of eq list block
  15. | EQforall of forall_handler
and 'a block = 'a block_desc localized
and 'a block_desc = {
  1. b_vars : vardec list;
  2. b_locals : local list;
  3. b_body : 'a;
}
and vardec = vardecdesc localized
and vardecdesc = {
  1. vardec_name : name;
  2. vardec_default : constant default option;
  3. vardec_combine : longname option;
}
and local = local_desc localized
and local_desc = is_rec * eq list
and statepat = statepatdesc localized
and statepatdesc =
  1. | Estate0pat of name
  2. | Estate1pat of name * name list
and state_exp = state_exp_desc localized
and state_exp_desc =
  1. | Estate0 of name
  2. | Estate1 of name * exp list
and escape = {
  1. e_cond : scondpat;
  2. e_reset : bool;
  3. e_block : eq list block option;
  4. e_next_state : state_exp;
}
and scondpat = scondpat_desc localized
and scondpat_desc =
  1. | Econdand of scondpat * scondpat
  2. | Econdor of scondpat * scondpat
  3. | Econdexp of exp
  4. | Econdon of scondpat * exp
  5. | Econdpat of exp * pattern
and is_on = bool
and 'a match_handler = {
  1. m_pat : pattern;
  2. m_body : 'a;
}
and 'a present_handler = {
  1. p_cond : scondpat;
  2. p_body : 'a;
}
and 'a state_handler_desc = {
  1. s_state : statepat;
  2. s_block : 'a block;
  3. s_until : escape list;
  4. s_unless : escape list;
}
and 'a state_handler = 'a state_handler_desc localized
and forall_handler = {
  1. for_indexes : indexes_desc localized list;
  2. for_init : init_desc localized list;
  3. for_body : eq list block;
}
and indexes_desc =
  1. | Einput of name * exp
  2. | Eoutput of name * name
  3. | Eindex of name * exp * exp
and init_desc =
  1. | Einit_last of name * exp