diff options
| author | Pierre-Marie Pédrot | 2021-04-23 23:38:26 +0200 |
|---|---|---|
| committer | Pierre-Marie Pédrot | 2021-04-23 23:38:26 +0200 |
| commit | d9e9a63f9f49768eee8b239812365ad1115b964f (patch) | |
| tree | 0d608882d4aa094ee6c519005696f272f14a2d27 /lib/loc.mli | |
| parent | 528f8384dcd817e4e339719a5d99c30d48520a8e (diff) | |
| parent | 4ca8b4aab1a6b4f55aab026e42a530fa125553c0 (diff) | |
Merge PR #14075: New level of abstraction for streams with (non-canonical) location function
Reviewed-by: ppedrot
Diffstat (limited to 'lib/loc.mli')
| -rw-r--r-- | lib/loc.mli | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/lib/loc.mli b/lib/loc.mli index c54a837bb4..2bbfaa5cce 100644 --- a/lib/loc.mli +++ b/lib/loc.mli @@ -45,6 +45,15 @@ val merge : t -> t -> t val merge_opt : t option -> t option -> t option (** Merge locations, usually generating the largest possible span *) +val sub : t -> int -> int -> t +(** [sub loc sh len] is the location [loc] shifted with [sh] + characters and with length [len]. The previous ending position + of the location is lost. *) + +val after : t -> int -> int -> t +(** [after loc sh len] is the location just after loc (starting at the + end position of [loc]) shifted with [sh] characters and of length [len]. *) + val finer : t option -> t option -> bool (** Answers [true] when the first location is more defined, or, when both defined, included in the second one *) |
