Up

module Merlin_lexer

: sig
#
type keywords = Raw_lexer.keywords
#
type item =
# | Error of Raw_lexer.error * Location.t
#
val item_start : item -> Lexing.position
#
val item_end : item -> Lexing.position
#
val empty : filename:string -> (exn list * item) History.t

Create an empty list new lexer

#
type t

Prepare for lexing. Returns the start position (end position of last valid token), and a lexing function that will append at most one token to the history at each call.

#
val history : t -> (exn list * item) History.t
#
val start : keywords -> (exn list * item) History.t -> t
#
val position : t -> Lexing.position
#
val feed : t -> string -> bool
#
val eof : t -> bool
#
val equal : item -> item -> bool
#
val put_mark : t -> Merlin_parser.frame option -> unit
#
val get_mark : t -> Merlin_parser.frame option
#
val reconstruct_identifier : ?for_locate:bool -> (exn list * item) History.t -> string Location.loc list
#
val identifier_suffix : string Location.loc list -> string Location.loc list
end