Commit 0f2e9c1a by POTTIER Francois

Document [top].

parent 40d92a65
......@@ -2514,6 +2514,17 @@ far, the type \verb+'a lr1state+ is abstract, so there is no way of
inspecting~\verb+s+. The inspection API (\sref{sec:inspection}) offers further
tools for this purpose.
%% val top
\begin{verbatim}
val top: 'a env -> element option
\end{verbatim}
\verb+top env+ returns the parser's top stack element. The state contained in
this stack element is the current state of the automaton. If the stack is
empty, \verb+None+ is returned. In that case, the current state of the
automaton must be an initial state.
%% val positions
\begin{verbatim}
......
......@@ -262,9 +262,10 @@ module type INCREMENTAL_ENGINE = sig
val stack: 'a env -> stack (* DEPRECATED *)
(* [top env] returns the parser's top stack cell. (If the stack is empty,
[None] is returned.) The state contained in this stack cell is the
current state of the automaton. *)
(* [top env] returns the parser's top stack element. The state contained in
this stack element is the current state of the automaton. If the stack is
empty, [None] is returned. In that case, the current state of the
automaton must be an initial state. *)
val top: 'a env -> element option
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment