[erlang-questions] Leex - a lexical anaylzer generator, released

Ben Hood 0x6e6562@REDACTED
Thu May 29 21:20:26 CEST 2008


Robert,

On 28 May 2008, at 00:56, Robert Virding wrote:
> Do you have a example that demonstrates glue code to create the  
> lexer and parser and then interpret a stream using the current code  
> base?
>
> That was it. You can check lfe_io.erl in the LFE and look at the  
> parse_file/1 and read_file/1 functions. I use my own parser as I  
> need it to return remaining tokens so I can read one sexpr at a  
> time. Yecc will not do this, although it wouldn't be difficult to  
> get to do it. :-(
>
> I will try to write a Rationale which describes the io system, and  
> other core features, in more detail and how it all hangs together.
>
> I hope that helped a little. Maybe others could point you to more  
> code using leex and parsers.

Thanks for your help. I've now gotten on top of leex and yecc to be  
able to solve my problem.

I wrote a general article about using leex and yecc, to maybe help  
other newcomers: http://hopper.squarespace.com/blog/2008/5/29/leex-and-yecc.html

HTH,

Ben





More information about the erlang-questions mailing list