type ('u, 's) mode = | Single | Parse a single s-expression | |||
| Many | Parse a list of s-expressions | |||
| Eager of {
} | Gives back s-expressions as soon as they are found. |
val empty_stack : stackval empty_stack_cst : stack_csttype ('u, 's) kind = | Positions : (Positions.Builder.t, unit) kind |
| Sexp : (unit, stack) kind |
| Sexp_with_positions : (Positions.Builder.t, stack) kind |
| Cst : (state_cst, stack_cst) kind |
val new_state : ?initial_pos:Positions.pos -> ('u, 's) mode -> ('u, 's) kind -> ('u, 's) stateval reset : ?pos:Positions.pos -> (_, _) state -> unitval positions : (Positions.Builder.t, _) state -> Positions.tval offset : (_, _) state -> intNumber of characters fed to the parser
val line : (_, _) state -> intPosition in the text
val column : (_, _) state -> intval has_unclosed_paren : ('u, 's) state -> boolWhether there are some unclosed parentheses
val set_error_state : (_, _) state -> unitval sexp_of_stack : stack -> Sexplib0.Sexp.tval sexps_of_stack : stack -> Sexplib0.Sexp.t listval sexps_cst_of_stack : stack_cst -> Cst.t_or_comment listmodule Error : sig ... endexception Parse_error of Error.tval feed : ('u, 's) state -> char -> 's -> 'sval feed_eoi : ('u, 's) state -> 's -> 's