Restore eof_reached
Signed-off-by: Rudi Grinberg <rudi.grinberg@gmail.com>
This commit is contained in:
parent
d6c35e01df
commit
6823fb0d43
|
@ -12,3 +12,5 @@ val first_line : Lexing.lexbuf -> first_line
|
||||||
(** Parse the first line of a versioned file but do not fail if it
|
(** Parse the first line of a versioned file but do not fail if it
|
||||||
doesn't start with [(lang ...)]. *)
|
doesn't start with [(lang ...)]. *)
|
||||||
val maybe_first_line : Lexing.lexbuf -> first_line option
|
val maybe_first_line : Lexing.lexbuf -> first_line option
|
||||||
|
|
||||||
|
val eof_reached : Lexing.lexbuf -> bool
|
||||||
|
|
|
@ -61,6 +61,10 @@ and to_eol = parse
|
||||||
{ ()
|
{ ()
|
||||||
}
|
}
|
||||||
|
|
||||||
|
and eof_reached = parse
|
||||||
|
| eof { true }
|
||||||
|
| "" { false }
|
||||||
|
|
||||||
{
|
{
|
||||||
let first_line lb =
|
let first_line lb =
|
||||||
match maybe_first_line lb with
|
match maybe_first_line lb with
|
||||||
|
|
Loading…
Reference in New Issue