package camlp5

  1. Overview
  2. Docs
type 'a parser_t = 'a Stream.t -> Obj.t
type 'a fparser_t = 'a Fstream.t -> (Obj.t * 'a Fstream.t) option
type !'a bparser_t = ('a, Obj.t) Fstream.bp
type parse_algorithm =
  1. | Predictive
  2. | Functional
  3. | Backtracking
  4. | DefaultAlgorithm
type !'te grammar = {
  1. gtokens : (Plexing.pattern, int ref) Hashtbl.t;
  2. mutable glexer : 'te Plexing.lexer;
  3. mutable galgo : parse_algorithm;
}
type !'te g_entry = {
  1. egram : 'te grammar;
  2. ename : string;
  3. elocal : bool;
  4. mutable estart : int -> 'te parser_t;
  5. mutable econtinue : int -> int -> Obj.t -> 'te parser_t;
  6. mutable fstart : int -> err_fun -> 'te fparser_t;
  7. mutable fcontinue : int -> int -> Obj.t -> err_fun -> 'te fparser_t;
  8. mutable bstart : int -> err_fun -> 'te bparser_t;
  9. mutable bcontinue : int -> int -> Obj.t -> err_fun -> 'te bparser_t;
  10. mutable edesc : 'te g_desc;
}
and !'te g_desc =
  1. | Dlevels of 'te g_level list
  2. | Dparser of 'te parser_t
and !'te g_level = {
  1. assoc : g_assoc;
  2. lname : string option;
  3. lsuffix : 'te g_tree;
  4. lprefix : 'te g_tree;
}
and g_assoc =
  1. | NonA
  2. | RightA
  3. | LeftA
and !'te g_symbol =
  1. | Sfacto of 'te g_symbol
  2. | Smeta of string * 'te g_symbol list * Obj.t
  3. | Snterm of 'te g_entry
  4. | Snterml of 'te g_entry * string
  5. | Slist0 of 'te g_symbol
  6. | Slist0sep of 'te g_symbol * 'te g_symbol * bool
  7. | Slist1 of 'te g_symbol
  8. | Slist1sep of 'te g_symbol * 'te g_symbol * bool
  9. | Sopt of 'te g_symbol
  10. | Sflag of 'te g_symbol
  11. | Sself
  12. | Snext
  13. | Scut
  14. | Stoken of Plexing.pattern
  15. | Stree of 'te g_tree
  16. | Svala of string list * 'te g_symbol
and g_action = Obj.t
and !'te g_tree =
  1. | Node of 'te g_node
  2. | LocAct of g_action * g_action list
  3. | DeadEnd
and !'te g_node = {
  1. node : 'te g_symbol;
  2. son : 'te g_tree;
  3. brother : 'te g_tree;
}
and err_fun = unit -> string
type position =
  1. | First
  2. | Last
  3. | Before of string
  4. | After of string
  5. | Like of string
  6. | Level of string
val levels_of_rules : 'te g_entry -> position option -> (string option * g_assoc option * ('te g_symbol list * g_action) list) list -> 'te g_level list
val srules : ('te g_symbol list * g_action) list -> 'te g_symbol
val action : 'a -> g_action
val eq_symbol : 'a g_symbol -> 'a g_symbol -> bool
val delete_rule_in_level_list : 'te g_entry -> 'te g_symbol list -> 'te g_level list -> 'te g_level list
val warning_verbose : bool ref
OCaml

Innovation. Community. Security.