Version française
Home     About     Download     Resources     Contact us    

This site is updated infrequently. For up-to-date information, please visit the new OCaml website at

Browse thread
[OSR] OCaml Standard Recommandation Process
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: 2008-01-29 (07:59)
From: Francois Pottier <Francois.Pottier@i...>
Subject: Re: [Caml-list] [OSR] OCaml Standard Recommandation Process


On Mon, Jan 28, 2008 at 09:43:55PM +0000, Dario Teixeira wrote:
> Another example that is probably so obvious that it almost doesn't need
> mentioning is the incompatibility of the lexer interface between ulex
> and Ocamlyacc/Menhir.

It would be possible for menhir to follow dypgen and allow the parser to
be parameterized over a lexer signature. I'll add that to the todo list.

In the meantime, another possibility would be to write a stub function that
makes ulex (or whatever lexer you are using) artificially look like an
ocamllex lexer. If I am not mistaken, all that is needed is to provide a
function of type Lexing.lexbuf -> token, which must update the fields
lex_start_p and lex_curr_p as a side effect.

François Pottier