sig
  module Genlex :
    sig
      type token =
        Extlib.ExtGenlex.Genlex.token =
          Kwd of string
        | Ident of string
        | Int of int
        | Float of float
        | String of string
        | Char of char
      type t = Extlib.ExtGenlex.Genlex.t
      val of_list : string list -> t
      val to_stream_filter : t -> char Stream.t -> token Stream.t
      val to_enum_filter : t -> char Extlib.Enum.t -> token Extlib.Enum.t
      val to_lazy_list_filter :
        t -> char Extlib.LazyList.t -> token Extlib.LazyList.t
      val make_lexer : string list -> char Stream.t -> token Stream.t
      module Languages :
        sig
          module type Definition =
            sig
              val comment_delimiters : (string * string) option
              val line_comment_start : string option
              val nested_comments : bool
              val ident_start :
                (char, char, Extlib.CharParser.position) Extlib.ParserCo.t
              val ident_letter :
                (char, char, Extlib.CharParser.position) Extlib.ParserCo.t
              val op_start :
                (char, char, Extlib.CharParser.position) Extlib.ParserCo.t
              val op_letter :
                (char, char, Extlib.CharParser.position) Extlib.ParserCo.t
              val reserved_names : string list
              val case_sensitive : bool
            end
          module Library :
            sig
              module OCaml :
                sig
                  val comment_delimiters : (string * string) option
                  val line_comment_start : string option
                  val nested_comments : bool
                  val ident_start :
                    (char, char, Extlib.CharParser.position)
                    Extlib.ParserCo.t
                  val ident_letter :
                    (char, char, Extlib.CharParser.position)
                    Extlib.ParserCo.t
                  val op_start :
                    (char, char, Extlib.CharParser.position)
                    Extlib.ParserCo.t
                  val op_letter :
                    (char, char, Extlib.CharParser.position)
                    Extlib.ParserCo.t
                  val reserved_names : string list
                  val case_sensitive : bool
                end
              module C :
                sig
                  val comment_delimiters : (string * string) option
                  val line_comment_start : string option
                  val nested_comments : bool
                  val ident_start :
                    (char, char, Extlib.CharParser.position)
                    Extlib.ParserCo.t
                  val ident_letter :
                    (char, char, Extlib.CharParser.position)
                    Extlib.ParserCo.t
                  val op_start :
                    (char, char, Extlib.CharParser.position)
                    Extlib.ParserCo.t
                  val op_letter :
                    (char, char, Extlib.CharParser.position)
                    Extlib.ParserCo.t
                  val reserved_names : string list
                  val case_sensitive : bool
                end
            end
          module Make :
            functor (M : Definition->
              sig
                val feed :
                  (char, Extlib.CharParser.position) Extlib.ParserCo.Source.t ->
                  (token, Extlib.CharParser.position)
                  Extlib.ParserCo.Source.t
                val start :
                  (char, unit, Extlib.CharParser.position) Extlib.ParserCo.t
                val ident :
                  (char, string, Extlib.CharParser.position)
                  Extlib.ParserCo.t
                val kwd :
                  (char, string, Extlib.CharParser.position)
                  Extlib.ParserCo.t
                val identifier :
                  string ->
                  (char, unit, Extlib.CharParser.position) Extlib.ParserCo.t
                val keyword :
                  string ->
                  (char, unit, Extlib.CharParser.position) Extlib.ParserCo.t
                val char_literal :
                  (char, char, Extlib.CharParser.position) Extlib.ParserCo.t
                val string_literal :
                  (char, string, Extlib.CharParser.position)
                  Extlib.ParserCo.t
                val integer :
                  (char, int, Extlib.CharParser.position) Extlib.ParserCo.t
                val float :
                  (char, float, Extlib.CharParser.position) Extlib.ParserCo.t
                val number :
                  (char, [ `Float of float | `Integer of int ],
                   Extlib.CharParser.position)
                  Extlib.ParserCo.t
                val char :
                  char ->
                  (char, char, Extlib.CharParser.position) Extlib.ParserCo.t
                val string :
                  string ->
                  (char, string, Extlib.CharParser.position)
                  Extlib.ParserCo.t
                val line_comment :
                  (char, unit, Extlib.CharParser.position) Extlib.ParserCo.t
                val multiline_comment :
                  (char, unit, Extlib.CharParser.position) Extlib.ParserCo.t
                val comment :
                  (char, unit, Extlib.CharParser.position) Extlib.ParserCo.t
                val whitespaces :
                  (char, unit, Extlib.CharParser.position) Extlib.ParserCo.t
              end
        end
    end
  module Char_parser :
    sig
      type position =
        Extlib.CharParser.position = {
        offset : int;
        line : int;
      }
      val advance : char -> position -> position
      val source_of_string :
        string -> (char, position) Extlib.ParserCo.Source.t
      val source_of_enum :
        char Extlib.Enum.t -> (char, position) Extlib.ParserCo.Source.t
      val parse :
        (char, 'a, position) Extlib.ParserCo.t ->
        string -> ('a, position Extlib.ParserCo.report) Extlib.Std.result
      val char : char -> (char, char, position) Extlib.ParserCo.t
      val none_of : char list -> (char, char, position) Extlib.ParserCo.t
      val not_char : char -> (char, char, position) Extlib.ParserCo.t
      val string : string -> (char, string, position) Extlib.ParserCo.t
      val case_char : char -> (char, char, position) Extlib.ParserCo.t
      val case_string : string -> (char, string, position) Extlib.ParserCo.t
      val newline : (char, char, position) Extlib.ParserCo.t
      val whitespace : (char, char, position) Extlib.ParserCo.t
      val uppercase : (char, char, position) Extlib.ParserCo.t
      val lowercase : (char, char, position) Extlib.ParserCo.t
      val letter : (char, char, position) Extlib.ParserCo.t
      val uppercase_latin1 : (char, char, position) Extlib.ParserCo.t
      val lowercase_latin1 : (char, char, position) Extlib.ParserCo.t
      val latin1 : (char, char, position) Extlib.ParserCo.t
      val digit : (char, char, position) Extlib.ParserCo.t
      val hex : (char, char, position) Extlib.ParserCo.t
    end
  module UChar_parser :
    sig
      type position =
        Extlib.CharParser.position = {
        offset : int;
        line : int;
      }
      val advance : Extlib.ExtUChar.UChar.t -> position -> position
      val source_of_rope :
        Extlib.Rope.t ->
        (Extlib.ExtUChar.UChar.t, position) Extlib.ParserCo.Source.t
      val source_of_enum :
        Extlib.ExtUChar.UChar.t Extlib.Enum.t ->
        (Extlib.ExtUChar.UChar.t, position) Extlib.ParserCo.Source.t
      val parse :
        (Extlib.ExtUChar.UChar.t, 'a, position) Extlib.ParserCo.t ->
        Extlib.Rope.t ->
        ('a, position Extlib.ParserCo.report) Extlib.Std.result
      val char :
        Extlib.ExtUChar.UChar.t ->
        (Extlib.ExtUChar.UChar.t, Extlib.ExtUChar.UChar.t, position)
        Extlib.ParserCo.t
      val none_of :
        Extlib.ExtUChar.UChar.t list ->
        (Extlib.ExtUChar.UChar.t, Extlib.ExtUChar.UChar.t, position)
        Extlib.ParserCo.t
      val not_char :
        Extlib.ExtUChar.UChar.t ->
        (Extlib.ExtUChar.UChar.t, Extlib.ExtUChar.UChar.t, position)
        Extlib.ParserCo.t
      val string :
        string ->
        (Extlib.ExtUChar.UChar.t, string, position) Extlib.ParserCo.t
      val rope :
        Extlib.Rope.t ->
        (Extlib.ExtUChar.UChar.t, Extlib.Rope.t, position) Extlib.ParserCo.t
      val ustring :
        Extlib.ExtUTF8.UTF8.t ->
        (Extlib.ExtUChar.UChar.t, Extlib.ExtUTF8.UTF8.t, position)
        Extlib.ParserCo.t
      val case_char :
        Extlib.ExtUChar.UChar.t ->
        (Extlib.ExtUChar.UChar.t, Extlib.ExtUTF8.UTF8.t, position)
        Extlib.ParserCo.t
      val case_string :
        string ->
        (Extlib.ExtUChar.UChar.t, string, position) Extlib.ParserCo.t
      val case_ustring :
        Extlib.ExtUTF8.UTF8.t ->
        (Extlib.ExtUChar.UChar.t, Extlib.ExtUTF8.UTF8.t, position)
        Extlib.ParserCo.t
      val case_rope :
        Extlib.Rope.t ->
        (Extlib.ExtUChar.UChar.t, Extlib.Rope.t, position) Extlib.ParserCo.t
      val newline :
        (Extlib.ExtUChar.UChar.t, Extlib.ExtUChar.UChar.t, position)
        Extlib.ParserCo.t
      val whitespace :
        (Extlib.ExtUChar.UChar.t, Extlib.ExtUChar.UChar.t, position)
        Extlib.ParserCo.t
      val uppercase :
        (Extlib.ExtUChar.UChar.t, Extlib.ExtUChar.UChar.t, position)
        Extlib.ParserCo.t
      val lowercase :
        (Extlib.ExtUChar.UChar.t, Extlib.ExtUChar.UChar.t, position)
        Extlib.ParserCo.t
      val letter :
        (Extlib.ExtUChar.UChar.t, Extlib.ExtUChar.UChar.t, position)
        Extlib.ParserCo.t
      val digit :
        (Extlib.ExtUChar.UChar.t, Extlib.ExtUChar.UChar.t, position)
        Extlib.ParserCo.t
      val hex :
        (Extlib.ExtUChar.UChar.t, Extlib.ExtUChar.UChar.t, position)
        Extlib.ParserCo.t
    end
  module Parser_co :
    sig
      type 'a state = 'Extlib.ParserCo.state = Eof | State of 'a
      type 'a report =
        'Extlib.ParserCo.report =
          Report of ('a state * string * 'a report) list
      module Source :
        sig
          type ('a, 'b) t = ('a, 'b) Extlib.ParserCo.Source.t
          val get_state : ('a, 'b) t -> 'b state
          val set_full_state :
            ('a, 'b) t -> '-> ('-> '-> 'c) -> ('a, 'c) t
          val of_enum :
            'Extlib.Enum.t -> '-> ('-> '-> 'b) -> ('a, 'b) t
        end
      type ('a, 'b, 'c) t = ('a, 'b, 'c) Extlib.ParserCo.t
      val eof : ('a, unit, 'b) t
      val either : ('a, 'b, 'c) t list -> ('a, 'b, 'c) t
      val ( <|> ) : ('a, 'b, 'c) t -> ('a, 'b, 'c) t -> ('a, 'b, 'c) t
      val maybe : ('a, 'b, 'c) t -> ('a, 'b option, 'c) t
      val ( ~? ) : ('a, 'b, 'c) t -> ('a, 'b option, 'c) t
      val bind : ('a, 'b, 'c) t -> ('-> ('a, 'd, 'c) t) -> ('a, 'd, 'c) t
      val ( >>= ) :
        ('a, 'b, 'c) t -> ('-> ('a, 'd, 'c) t) -> ('a, 'd, 'c) t
      val ( >>> ) : ('a, 'b, 'c) t -> ('a, 'd, 'c) t -> ('a, 'd, 'c) t
      val cons : ('a, 'b, 'c) t -> ('a, 'b list, 'c) t -> ('a, 'b list, 'c) t
      val ( >:: ) :
        ('a, 'b, 'c) t -> ('a, 'b list, 'c) t -> ('a, 'b list, 'c) t
      val label : string -> ('a, 'b, 'c) t -> ('a, 'b, 'c) t
      val state : ('a, 'b state, 'b) t
      val any : ('a, 'a, 'b) t
      val return : '-> ('b, 'a, 'c) t
      val satisfy : ('-> bool) -> ('a, 'a, 'b) t
      val filter : ('-> bool) -> ('b, 'a, 'c) t -> ('b, 'a, 'c) t
      val run :
        ('a, 'b, 'c) t ->
        ('a, 'c) Source.t -> ('b, 'c report) Extlib.Std.result
      val fail : ('a, 'b, 'c) t
      val fatal : ('a, 'b, 'c) t
      val lookahead : ('a, 'b, 'c) t -> ('a, 'b option, 'c) t
      val exactly : '-> ('a, 'a, 'b) t
      val one_of : 'a list -> ('a, 'a, 'b) t
      val none_of : 'a list -> ('a, 'a, 'b) t
      val range : '-> '-> ('a, 'a, 'b) t
      val zero_plus :
        ?sep:('a, 'b, 'c) t -> ('a, 'd, 'c) t -> ('a, 'd list, 'c) t
      val ignore_zero_plus :
        ?sep:('a, 'b, 'c) t -> ('a, 'd, 'c) t -> ('a, unit, 'c) t
      val ( ~* ) : ('a, 'b, 'c) t -> ('a, 'b list, 'c) t
      val one_plus :
        ?sep:('a, 'b, 'c) t -> ('a, 'd, 'c) t -> ('a, 'd list, 'c) t
      val ignore_one_plus :
        ?sep:('a, 'b, 'c) t -> ('a, 'd, 'c) t -> ('a, unit, 'c) t
      val ( ~+ ) : ('a, 'b, 'c) t -> ('a, 'b list, 'c) t
      val times : int -> ('a, 'b, 'c) t -> ('a, 'b list, 'c) t
      val ( ^^ ) : ('a, 'b, 'c) t -> int -> ('a, 'b list, 'c) t
      val must : ('a, 'b, 'c) t -> ('a, 'b, 'c) t
      val should : ('a, 'b, 'c) t -> ('a, 'b, 'c) t
      val post_map : ('-> 'b) -> ('c, 'a, 'd) t -> ('c, 'b, 'd) t
      val source_map :
        ('a, 'b, 'c) t -> ('a, 'c) Source.t -> ('b, 'c) Source.t
      val scan : ('a, 'b, 'c) t -> ('a, 'a list, 'c) t
      val sat : ('-> bool) -> ('a, unit, 'b) t
      val debug_mode : bool ref
    end
  module Path :
    sig
      type ustring = string
      type uchar = char
      module OperatorLift : sig val ( !! ) : string -> ustring end
      type t = ustring list
      val is_relative : t -> bool
      val is_absolute : t -> bool
      val root : t
      val append : t -> ustring -> t
      val concat : t -> t -> t
      module Operators :
        sig val ( /: ) : t -> ustring -> t val ( //@ ) : t -> t -> t end
      exception Malformed_path
      val normalize : t -> t
      val parent : t -> t
      val belongs : t -> t -> bool
      val relative_to_any : t -> t -> t
      exception Not_parent
      val relative_to_parent : t -> t -> t
      exception Illegal_char
      type validator = ustring -> bool
      val default_validator : validator ref
      val to_ustring : t -> ustring
      val to_string : t -> string
      val of_string : ustring -> t
      val s : t -> string
      val p : ustring -> t
      val name : t -> ustring
      val map_name : (ustring -> ustring) -> t -> t
      val ext : t -> ustring option
      val map_ext : (ustring option -> ustring option) -> t -> t
      val name_core : t -> ustring
      type components = t * ustring * ustring option
      val split : t -> components
      val join : components -> t
      val map : (components -> components) -> t -> t
      val drive_letter : t -> uchar option
    end
  module PathGen :
    sig
      module type StringType =
        sig
          type t
          val length : t -> int
          type tchar
          val get : t -> int -> tchar
          val lift_char : char -> tchar
          val lift : string -> t
          val to_string : t -> string
          val concat_with_separators : t -> t list -> t
          val compare : t -> t -> int
          val iter : (tchar -> unit) -> t -> unit
          val iteri : (int -> tchar -> unit) -> t -> unit
          val sub : t -> int -> int -> t
          val rindex : t -> char -> int
          module Parse :
            sig
              val source :
                t ->
                (tchar, Extlib.CharParser.position) Extlib.ParserCo.Source.t
              val letter :
                (tchar, tchar, Extlib.CharParser.position) Extlib.ParserCo.t
            end
        end
      module type PathType =
        sig
          type ustring
          type uchar
          module OperatorLift : sig val ( !! ) : string -> ustring end
          type t = ustring list
          val is_relative : t -> bool
          val is_absolute : t -> bool
          val root : t
          val append : t -> ustring -> t
          val concat : t -> t -> t
          module Operators :
            sig val ( /: ) : t -> ustring -> t val ( //@ ) : t -> t -> t end
          exception Malformed_path
          val normalize : t -> t
          val parent : t -> t
          val belongs : t -> t -> bool
          val relative_to_any : t -> t -> t
          exception Not_parent
          val relative_to_parent : t -> t -> t
          exception Illegal_char
          type validator = ustring -> bool
          val default_validator : validator ref
          val to_ustring : t -> ustring
          val to_string : t -> string
          val of_string : ustring -> t
          val s : t -> string
          val p : ustring -> t
          val name : t -> ustring
          val map_name : (ustring -> ustring) -> t -> t
          val ext : t -> ustring option
          val map_ext : (ustring option -> ustring option) -> t -> t
          val name_core : t -> ustring
          type components = t * ustring * ustring option
          val split : t -> components
          val join : components -> t
          val map : (components -> components) -> t -> t
          val drive_letter : t -> uchar option
        end
      module Make :
        functor (S : StringType->
          sig
            type ustring = S.t
            type uchar = S.tchar
            module OperatorLift : sig val ( !! ) : string -> ustring end
            type t = ustring list
            val is_relative : t -> bool
            val is_absolute : t -> bool
            val root : t
            val append : t -> ustring -> t
            val concat : t -> t -> t
            module Operators :
              sig
                val ( /: ) : t -> ustring -> t
                val ( //@ ) : t -> t -> t
              end
            exception Malformed_path
            val normalize : t -> t
            val parent : t -> t
            val belongs : t -> t -> bool
            val relative_to_any : t -> t -> t
            exception Not_parent
            val relative_to_parent : t -> t -> t
            exception Illegal_char
            type validator = ustring -> bool
            val default_validator : validator ref
            val to_ustring : t -> ustring
            val to_string : t -> string
            val of_string : ustring -> t
            val s : t -> string
            val p : ustring -> t
            val name : t -> ustring
            val map_name : (ustring -> ustring) -> t -> t
            val ext : t -> ustring option
            val map_ext : (ustring option -> ustring option) -> t -> t
            val name_core : t -> ustring
            type components = t * ustring * ustring option
            val split : t -> components
            val join : components -> t
            val map : (components -> components) -> t -> t
            val drive_letter : t -> uchar option
          end
      module OfString :
        sig
          type ustring = string
          type uchar = char
          module OperatorLift : sig val ( !! ) : string -> ustring end
          type t = ustring list
          val is_relative : t -> bool
          val is_absolute : t -> bool
          val root : t
          val append : t -> ustring -> t
          val concat : t -> t -> t
          module Operators :
            sig val ( /: ) : t -> ustring -> t val ( //@ ) : t -> t -> t end
          exception Malformed_path
          val normalize : t -> t
          val parent : t -> t
          val belongs : t -> t -> bool
          val relative_to_any : t -> t -> t
          exception Not_parent
          val relative_to_parent : t -> t -> t
          exception Illegal_char
          type validator = ustring -> bool
          val default_validator : validator ref
          val to_ustring : t -> ustring
          val to_string : t -> string
          val of_string : ustring -> t
          val s : t -> string
          val p : ustring -> t
          val name : t -> ustring
          val map_name : (ustring -> ustring) -> t -> t
          val ext : t -> ustring option
          val map_ext : (ustring option -> ustring option) -> t -> t
          val name_core : t -> ustring
          type components = t * ustring * ustring option
          val split : t -> components
          val join : components -> t
          val map : (components -> components) -> t -> t
          val drive_letter : t -> uchar option
        end
    end
  module Result :
    sig
      type ('a, 'b) t = ('a, 'b) Extlib.Std.result
      val catch : ('-> 'b) -> '-> ('b, exn) Extlib.Std.result
      val of_option : 'a option -> ('a, unit) Extlib.Std.result
      val to_option : ('a, 'b) Extlib.Std.result -> 'a option
      val bind :
        ('a, 'b) Extlib.Std.result ->
        ('-> ('c, 'b) Extlib.Std.result) -> ('c, 'b) Extlib.Std.result
      val ( >>= ) :
        ('a, 'b) Extlib.Std.result ->
        ('-> ('c, 'b) Extlib.Std.result) -> ('c, 'b) Extlib.Std.result
      val t_of_sexp :
        (Sexplib.Sexp.t -> 'a) ->
        (Sexplib.Sexp.t -> 'b) -> Sexplib.Sexp.t -> ('a, 'b) t
      val sexp_of_t :
        ('-> Sexplib.Sexp.t) ->
        ('-> Sexplib.Sexp.t) -> ('a, 'b) t -> Sexplib.Sexp.t
    end
  module Logger :
    sig
      type log = Extlib.Logger.log
      type level =
        Extlib.Logger.level =
          NONE
        | FATAL
        | ERROR
        | WARN
        | NOTICE
        | INFO
        | DEBUG
      val make_log : string -> log
      val log_name : log -> string
      val log_enable : log -> level -> unit
      val log_level : log -> level
      val log_enabled : log -> level -> bool
      type event = string * (string * string) list
      val log : log -> level -> (unit -> event) -> unit
      val with_log :
        log ->
        level ->
        (unit -> event) -> ?result:('-> string) -> (unit -> 'a) -> 'a
      type formatter = log -> level -> event -> float -> unit
      val register_formatter : string -> formatter -> unit
      val unregister_formatter : string -> unit
      val make_std_formatter : out_channel -> formatter
      val stderr_formatter : formatter
      val null_formatter : formatter
      val make_dbg_formatter : out_channel -> formatter
      val dbg_formatter : formatter
      val init : (string * level) list -> formatter -> unit
      val init_from_string : string -> formatter -> unit
      val level_of_name : string -> level
      val name_of_level : level -> string
      val format_timestamp : out_channel -> float -> unit
    end
end