|Wanted: advice on writing compiler in Perl! email@example.com (1996-05-14)|
|Re: Wanted: advice on writing compiler in Perl! firstname.lastname@example.org (1996-05-19)|
|Re: Wanted: advice on writing compiler in Perl! trulsson@Minsk.docs.uu.se (1996-05-21)|
|Re: Wanted: advice on writing compiler in Perl! email@example.com (1996-05-24)|
|From:||firstname.lastname@example.org (Edward Walker)|
|Date:||24 May 1996 15:34:12 -0400|
|Organization:||National University of Singapore|
|References:||96-05-099 96-05-110 96-05-135|
Erik Trulsson (trulsson@Minsk.docs.uu.se) wrote:
: Brian N. Miller <email@example.com> wrote:
: > Perl has some very helpful features for compiler writing:
: > [regular expressions, hash tables, lists, and file I/O]
: > But I couldn't find any ready-to-use general parsing toolkits for
: > perl. And I'm not happy with the quality of perl debuggers.
: There exists a version of Berkely Yacc v1.8.2 that can emit
: Perl code as well as C code so you can use normal yacc code
: for parsing. And since Perl is very good at regular expressions
: you don't really need lex.
I beg to differ. Systems like flex, lex and others do more then
match regular expressions. They generate DFAs so that tokens
<token> END DO
can be disambiguated. If you intend to use perl to do
this, the order in which you search for your tokens must be
carefully arranged, or a wrong token will be returned.
Actually if you look at Larry Wall's TODO list, a perllex
is at the top of it.
Dr Edward Walker
National Supercomputing Research Centre
81, Science Park Drive
Return to the
Search the comp.compilers archives again.