package merlin-lib

  1. Overview
  2. Docs
On This Page
  1. Dump
Legend:
Library
Module
Module type
Parameter
Class
Class type
type t = Location.t = {
  1. loc_start : Lexing.position;
  2. loc_end : Lexing.position;
  3. loc_ghost : bool;
}
val compare : t -> t -> int

compare l1 l2 compares start positions, if equal compares end positions

val compare_pos : Lexing.position -> t -> int
val union : t -> t -> t

Return the smallest location covered by both arguments, ghost if both are ghosts

val extend : t -> t -> t

Like location_union, but keep loc_ghost'ness of first argument

val included : into:t -> t -> bool

included ~into:parent child returns true if child is included in parent. Otherwise returns false.

val overlap_with_range : (Lexing.position * Lexing.position) -> t -> bool

overlap_with_range (pos_start, pos_end) loc returns true if loc overlap with the range defined by pos_start and pos_end.

val prepare_errors : exn list -> Location.error list

Filter valid errors, log invalid ones

Dump

val print : unit -> t -> string
val print_loc : (unit -> 'a -> string) -> unit -> 'a Location.loc -> string
val is_relaxed_location : string Location.loc -> bool
OCaml

Innovation. Community. Security.