package reparse

  1. Overview
  2. Docs

Represents a generalization of data input source to a parser. Implement this interface to provide new sources of input to Reparse.parse.

method eof : int -> bool

i#eof offset returns true if offset position in i represents the end of input.

method sub : offset:int -> len:int -> string

i#sub t ~offset ~len reads and returns a string of length len at position offset from input i. May return a string of length less than len.

method nth : int -> char

i#nth n returns the nth char from input i.

  • raises End_of_file

    if n is at eof.