diff options
author | Pascal Rigaux <pixel@mandriva.com> | 2003-12-15 15:18:25 +0000 |
---|---|---|
committer | Pascal Rigaux <pixel@mandriva.com> | 2003-12-15 15:18:25 +0000 |
commit | b617ff518050ff8e33ab142f18b280d1e880c447 (patch) | |
tree | b124574d370efc15e37493fb1fcd66db0aa6226e /perl_checker.src | |
parent | 75e263477d662fea4b03bc6b6561b6b74ad8c367 (diff) | |
download | perl-MDK-Common-b617ff518050ff8e33ab142f18b280d1e880c447.tar perl-MDK-Common-b617ff518050ff8e33ab142f18b280d1e880c447.tar.gz perl-MDK-Common-b617ff518050ff8e33ab142f18b280d1e880c447.tar.bz2 perl-MDK-Common-b617ff518050ff8e33ab142f18b280d1e880c447.tar.xz perl-MDK-Common-b617ff518050ff8e33ab142f18b280d1e880c447.zip |
update "faking a normal lexbuf" code for new ocaml's parsing.ml
Diffstat (limited to 'perl_checker.src')
-rw-r--r-- | perl_checker.src/parser_helper.ml | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/perl_checker.src/parser_helper.ml b/perl_checker.src/parser_helper.ml index ba30b58..a07ad38 100644 --- a/perl_checker.src/parser_helper.ml +++ b/perl_checker.src/parser_helper.ml @@ -897,9 +897,9 @@ let rec list2tokens l = match !rl with | [] -> internal_error "list2tokens" | ((start, end_), e) :: l -> - lexbuf.Lexing.lex_abs_pos <- 0 ; - lexbuf.Lexing.lex_start_pos <- start ; - lexbuf.Lexing.lex_curr_pos <- end_ ; + (* HACK: fake a normal lexbuf *) + lexbuf.Lexing.lex_start_p <- { Lexing.dummy_pos with Lexing.pos_cnum = start } ; + lexbuf.Lexing.lex_curr_p <- { Lexing.dummy_pos with Lexing.pos_cnum = end_ } ; rl := l ; e let parse_tokens parse tokens lexbuf_opt = |