`sig
type t
type rope = Rope.t
exception Out_of_bounds of string
val empty : Rope.t
val of_string : string -> Rope.t
val of_substring : string -> int -> int -> Rope.t
val of_char : char -> Rope.t
val make : int -> char -> Rope.t
val init : int -> (int -> char) -> Rope.t
val to_string : Rope.t -> string
val is_empty : Rope.t -> bool
val length : Rope.t -> int
val get : Rope.t -> int -> char
val sub : Rope.t -> int -> int -> Rope.t
val blit : Rope.t -> int -> Stdlib.Bytes.t -> int -> int -> unit
val concat2 : Rope.t -> Rope.t -> Rope.t
val concat : Rope.t -> Rope.t list -> Rope.t
val iter : (char -> unit) -> Rope.t -> unit
val iteri : (int -> char -> unit) -> Rope.t -> unit
val map : f:(char -> char) -> Rope.t -> Rope.t
val mapi : f:(int -> char -> char) -> Rope.t -> Rope.t
val trim : Rope.t -> Rope.t
val escaped : Rope.t -> Rope.t
val index : Rope.t -> char -> int
val index_opt : Rope.t -> char -> int option
val rindex : Rope.t -> char -> int
val rindex_opt : Rope.t -> char -> int option
val index_from : Rope.t -> int -> char -> int
val index_from_opt : Rope.t -> int -> char -> int option
val rindex_from : Rope.t -> int -> char -> int
val rindex_from_opt : Rope.t -> int -> char -> int option
val contains : Rope.t -> char -> bool
val contains_from : Rope.t -> int -> char -> bool
val rcontains_from : Rope.t -> int -> char -> bool
val search_forward_string : string -> Rope.t -> int -> int
val uppercase_ascii : Rope.t -> Rope.t
val lowercase_ascii : Rope.t -> Rope.t
val capitalize_ascii : Rope.t -> Rope.t
val uncapitalize_ascii : Rope.t -> Rope.t
val uppercase : Rope.t -> Rope.t
val lowercase : Rope.t -> Rope.t
val capitalize : Rope.t -> Rope.t
val uncapitalize : Rope.t -> Rope.t
val compare : Rope.t -> Rope.t -> int
val equal : Rope.t -> Rope.t -> bool
val input_line : ?leaf_length:int -> Stdlib.in_channel -> Rope.t
val read_line : unit -> Rope.t
val print_string : Rope.t -> unit
val print_endline : Rope.t -> unit
val prerr_string : Rope.t -> unit
val prerr_endline : Rope.t -> unit
val output_rope : Stdlib.out_channel -> Rope.t -> unit
val output_string : Stdlib.out_channel -> Rope.t -> unit
val balance : Rope.t -> Rope.t
val height : Rope.t -> int
val rebalancing_height : int
module Iterator :
sig
type t
val make : Rope.rope -> int -> Rope.Iterator.t
val get : Rope.Iterator.t -> char
val peek : Rope.Iterator.t -> int -> char
val pos : Rope.Iterator.t -> int
val incr : Rope.Iterator.t -> unit
val decr : Rope.Iterator.t -> unit
val goto : Rope.Iterator.t -> int -> unit
val move : Rope.Iterator.t -> int -> unit
val rope : Rope.Iterator.t -> Rope.rope
end
module Buffer :
sig
type t
val create : int -> Rope.Buffer.t
val clear : Rope.Buffer.t -> unit
val reset : Rope.Buffer.t -> unit
val length : Rope.Buffer.t -> int
val add_char : Rope.Buffer.t -> char -> unit
val add_string : Rope.Buffer.t -> string -> unit
val add_substring : Rope.Buffer.t -> string -> int -> int -> unit
val add_rope : Rope.Buffer.t -> Rope.rope -> unit
val add_channel : Rope.Buffer.t -> Stdlib.in_channel -> int -> unit
val add_buffer : Rope.Buffer.t -> Rope.Buffer.t -> unit
val contents : Rope.Buffer.t -> Rope.rope
val sub : Rope.Buffer.t -> int -> int -> Rope.rope
val nth : Rope.Buffer.t -> int -> char
end
module Rope_toploop :
sig
val printer : Stdlib.Format.formatter -> Rope.rope -> unit
val max_display_length : int Stdlib.ref
val ellipsis : string Stdlib.ref
end
val number_leaves : Rope.t -> int
val number_concat : Rope.t -> int
val print : Rope.t -> unit
val length_leaves : Rope.t -> int * int
module IMap :
sig
type key = int
type +!'a t
val empty : 'a t
val add : key -> 'a -> 'a t -> 'a t
val add_to_list : key -> 'a -> 'a list t -> 'a list t
val update : key -> ('a option -> 'a option) -> 'a t -> 'a t
val singleton : key -> 'a -> 'a t
val remove : key -> 'a t -> 'a t
val merge :
(key -> 'a option -> 'b option -> 'c option) -> 'a t -> 'b t -> 'c t
val union : (key -> 'a -> 'a -> 'a option) -> 'a t -> 'a t -> 'a t
val cardinal : 'a t -> int
val bindings : 'a t -> (key * 'a) list
val min_binding : 'a t -> key * 'a
val min_binding_opt : 'a t -> (key * 'a) option
val max_binding : 'a t -> key * 'a
val max_binding_opt : 'a t -> (key * 'a) option
val choose : 'a t -> key * 'a
val choose_opt : 'a t -> (key * 'a) option
val find : key -> 'a t -> 'a
val find_opt : key -> 'a t -> 'a option
val find_first : (key -> bool) -> 'a t -> key * 'a
val find_first_opt : (key -> bool) -> 'a t -> (key * 'a) option
val find_last : (key -> bool) -> 'a t -> key * 'a
val find_last_opt : (key -> bool) -> 'a t -> (key * 'a) option
val iter : (key -> 'a -> unit) -> 'a t -> unit
val fold : (key -> 'a -> 'acc -> 'acc) -> 'a t -> 'acc -> 'acc
val map : ('a -> 'b) -> 'a t -> 'b t
val mapi : (key -> 'a -> 'b) -> 'a t -> 'b t
val filter : (key -> 'a -> bool) -> 'a t -> 'a t
val filter_map : (key -> 'a -> 'b option) -> 'a t -> 'b t
val partition : (key -> 'a -> bool) -> 'a t -> 'a t * 'a t
val split : key -> 'a t -> 'a t * 'a option * 'a t
val is_empty : 'a t -> bool
val mem : key -> 'a t -> bool
val equal : ('a -> 'a -> bool) -> 'a t -> 'a t -> bool
val compare : ('a -> 'a -> int) -> 'a t -> 'a t -> int
val for_all : (key -> 'a -> bool) -> 'a t -> bool
val exists : (key -> 'a -> bool) -> 'a t -> bool
val to_list : 'a t -> (key * 'a) list
val of_list : (key * 'a) list -> 'a t
val to_seq : 'a t -> (key * 'a) Seq.t
val to_rev_seq : 'a t -> (key * 'a) Seq.t
val to_seq_from : key -> 'a t -> (key * 'a) Seq.t
val add_seq : (key * 'a) Seq.t -> 'a t -> 'a t
val of_seq : (key * 'a) Seq.t -> 'a t
end
val distrib_leaves : Rope.t -> int Stdlib.ref Rope.IMap.t
end`