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
[Caml-list] start conditions in ocamllex
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: 2004-02-26 (02:51)
From: skaller <skaller@u...>
Subject: [Caml-list] Plea for arguments to Ocamlyacc generated parsers
On Thu, 2004-02-26 at 06:23, Kenneth Knowles wrote:
> > > Has anyone thought of implementing start conditions for ocamllex?

I find it is useful to have a Ocaml class specifying lexer state
and passing objects thereof to the lexer. It has always
been possible to do this, but now the lexer makes the notation
easier (saves writing fun state -> ... for every match)

I sorely need the same ability to pass a state argument 
to the parser!!! As far as I know it can't be done at all
(without hacking the generated code).

Please could we have that? I'd sure like to be able
to parse C without using a global variable -- I have a strong
belief in writing re-entrant code which I'd hope all functional
programmers would share :D

John Skaller,
voice: 061-2-9660-0850, 
snail: PO BOX 401 Glebe NSW 2037 Australia
Checkout the Felix programming language

To unsubscribe, mail Archives:
Bug reports: FAQ:
Beginner's list: