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 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147
|
module type S = sig
type position = Lexing.position =
{
pos_fname: string ;
pos_lnum: int ;
pos_bol: int ;
pos_cnum: int }
(** Alias for {!Lexing.position} *)
@BEGIN_FROM_4_02_0@
type lexbuf = Lexing.lexbuf =
{
refill_buff: lexbuf -> unit ;
mutable lex_buffer: bytes ;
mutable lex_buffer_len: int ;
mutable lex_abs_pos: int ;
mutable lex_start_pos: int ;
mutable lex_curr_pos: int ;
mutable lex_last_pos: int ;
mutable lex_last_action: int ;
mutable lex_eof_reached: bool ;
mutable lex_mem: int array ;
mutable lex_start_p: position ;
mutable lex_curr_p: position }
@END_FROM_4_02_0@
@BEGIN_BEFORE_4_02_0@
type lexbuf = Lexing.lexbuf =
{
refill_buff: lexbuf -> unit ;
mutable lex_buffer: Stdcompat__init.bytes ;
mutable lex_buffer_len: int ;
mutable lex_abs_pos: int ;
mutable lex_start_pos: int ;
mutable lex_curr_pos: int ;
mutable lex_last_pos: int ;
mutable lex_last_action: int ;
mutable lex_eof_reached: bool ;
mutable lex_mem: int array ;
mutable lex_start_p: position ;
mutable lex_curr_p: position }
@END_BEFORE_4_02_0@
(** @since 4.02.0:
type lexbuf =
{
refill_buff: lexbuf -> unit ;
mutable lex_buffer: bytes ;
mutable lex_buffer_len: int ;
mutable lex_abs_pos: int ;
mutable lex_start_pos: int ;
mutable lex_curr_pos: int ;
mutable lex_last_pos: int ;
mutable lex_last_action: int ;
mutable lex_eof_reached: bool ;
mutable lex_mem: int array ;
mutable lex_start_p: position ;
mutable lex_curr_p: position }
*)
type lex_tables = Lexing.lex_tables =
{
lex_base: string ;
lex_backtrk: string ;
lex_default: string ;
lex_trans: string ;
lex_check: string ;
lex_base_code: string ;
lex_backtrk_code: string ;
lex_default_code: string ;
lex_trans_code: string ;
lex_check_code: string ;
lex_code: string }
(** Alias for {!Lexing.lex_tables} *)
val set_position : lexbuf -> position -> unit
(** @since 4.11.0: val set_position : lexbuf -> position -> unit *)
val set_filename : lexbuf -> string -> unit
(** @since 4.11.0: val set_filename : lexbuf -> string -> unit *)
val from_channel : ?with_positions:bool -> in_channel -> lexbuf
(** @since 4.08.0:
val from_channel : ?with_positions:bool -> in_channel -> lexbuf *)
val from_string : ?with_positions:bool -> string -> lexbuf
(** @since 4.08.0: val from_string : ?with_positions:bool -> string -> lexbuf *)
@BEGIN_FROM_4_08_0@
val from_function : ?with_positions:bool -> (bytes -> int -> int) -> lexbuf
@END_FROM_4_08_0@
@BEGIN_BEFORE_4_08_0@
val from_function :
?with_positions:bool -> (Stdcompat__init.bytes -> int -> int) -> lexbuf
@END_BEFORE_4_08_0@
(** @since 4.08.0:
val from_function :
?with_positions:bool -> (bytes -> int -> int) -> lexbuf
*)
val with_positions : lexbuf -> bool
(** @since 4.08.0: val with_positions : lexbuf -> bool *)
val new_line : lexbuf -> unit
(** @since 3.11.0: val new_line : lexbuf -> unit *)
val dummy_pos : position
(** Alias for {!Lexing.dummy_pos} *)
val lexeme : lexbuf -> string
(** Alias for {!Lexing.lexeme} *)
val lexeme_char : lexbuf -> int -> char
(** Alias for {!Lexing.lexeme_char} *)
val lexeme_start : lexbuf -> int
(** Alias for {!Lexing.lexeme_start} *)
val lexeme_end : lexbuf -> int
(** Alias for {!Lexing.lexeme_end} *)
val lexeme_start_p : lexbuf -> position
(** Alias for {!Lexing.lexeme_start_p} *)
val lexeme_end_p : lexbuf -> position
(** Alias for {!Lexing.lexeme_end_p} *)
val flush_input : lexbuf -> unit
(** Alias for {!Lexing.flush_input} *)
val sub_lexeme : lexbuf -> int -> int -> string
(** Alias for {!Lexing.sub_lexeme} *)
val sub_lexeme_opt : lexbuf -> int -> int -> string option
(** Alias for {!Lexing.sub_lexeme_opt} *)
val sub_lexeme_char : lexbuf -> int -> char
(** Alias for {!Lexing.sub_lexeme_char} *)
val sub_lexeme_char_opt : lexbuf -> int -> char option
(** Alias for {!Lexing.sub_lexeme_char_opt} *)
val engine : lex_tables -> int -> lexbuf -> int
(** Alias for {!Lexing.engine} *)
val new_engine : lex_tables -> int -> lexbuf -> int
(** Alias for {!Lexing.new_engine} *)
end
|