-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathtypes.ml
36 lines (28 loc) · 1.24 KB
/
types.ml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
(************************************************************************)
(* * The Coq Proof Assistant / The Coq Development Team *)
(* v * INRIA, CNRS and contributors - Copyright 1999-2019 *)
(* <O___,, * (see CREDITS file for the list of authors) *)
(* \VV/ **************************************************************)
(* // * This file is distributed under the terms of the *)
(* * GNU Lesser General Public License Version 2.1 *)
(* * (see LICENSE file for the text of the license) *)
(************************************************************************)
type sentence_id = Stateid.t
type sentence_id_set = Stateid.Set.t
type ast = Vernacexpr.vernac_control
module Position : sig
type t = { line : int; char : int }
val compare : t -> t -> int
val to_string : t -> string
end = struct
type t = { line : int; char : int; }
let compare pos1 pos2 =
match Int.compare pos1.line pos2.line with
| 0 -> Int.compare pos1.char pos2.char
| x -> x
let to_string pos = Format.sprintf "(%i,%i)" pos.line pos.char
end
module Range = struct
type t = { start : Position.t; stop : Position.t; }
end
type text_edit = Range.t * string