diff options
author | Chimrod <> | 2023-09-29 09:27:22 +0200 |
---|---|---|
committer | Chimrod <> | 2023-09-29 10:00:21 +0200 |
commit | 1f79e8f1f0f59748497665ccee544163c5136562 (patch) | |
tree | eacf55e9a2b5b8ace25d3f118f9b749ae9b53dbc /lib/lexbuf.mli | |
parent | 5e0b521a2ccce4bd19cf5d08176616f760180c11 (diff) |
Fixed a wrong location for string
Diffstat (limited to 'lib/lexbuf.mli')
-rw-r--r-- | lib/lexbuf.mli | 13 |
1 files changed, 12 insertions, 1 deletions
diff --git a/lib/lexbuf.mli b/lib/lexbuf.mli index cf93c7e..b058f3c 100644 --- a/lib/lexbuf.mli +++ b/lib/lexbuf.mli @@ -1,8 +1,19 @@ type t +val from_lexbuf : Sedlexing.lexbuf -> t +(** Create a new buffer *) + val start : t -> unit +(** Intialize a new run *) + val buffer : t -> Sedlexing.lexbuf +(** Extract the sedlex buffer. Required in each rule. *) + val positions : t -> Lexing.position * Lexing.position +(** Extract the starting and ending position for the matched token *) + val content : t -> string -val from_lexbuf : Sedlexing.lexbuf -> t +(** Extract the token matched by the rule *) + +val set_start_position : t -> Lexing.position -> unit val tokenize : (t -> 'a) -> t -> unit -> 'a * Lexing.position * Lexing.position |