Class Cf_parser.cursor


class ['a] cursor : int -> object .. end
A class useful for tracking the position in the input token stream that corresponds to the head of the sequence passed to a parser. The #cursor class type is used in the X module defined below.

val position_ : int
The initial position, i.e. usually zero

The current position

method advance : 'a -> < advance : 'b; position : int; .. > as 'b
Use c#advance i to construct a new object corresponding to the new input position after reading an input symbol i.
method position : int
Returns the current position.