Related articles |
---|
Why separate Lexical & Parser Generators heronj@smtplink.NGC.COM (John Heron) (1994-10-05) |
Re: Why separate Lexical & Parser Generators andand@csd.uu.se (Anders Andersson) (1994-10-06) |
Re: Why separate Lexical & Parser Generators leichter@zodiac.rutgers.edu (1994-10-06) |
Re: Why separate Lexical & Parser Generators morrison@hal.cs.uiuc.edu (1994-10-07) |
Re: Why separate Lexical & Parser Generators johnl@cs.indiana.edu (John Lacey) (1994-10-10) |
Re: Why separate Lexical & Parser Generators hagerman@ece.cmu.edu (1994-10-10) |
Re: Why separate Lexical & Parser Generators wrs@apple.com (Walter Smith) (1994-10-10) |
Re: Why separate Lexical & Parser Generators cef@geodesic.com (Charles Fiterman) (1994-10-11) |
[5 later articles] |
Newsgroups: | comp.compilers |
From: | Anders Andersson <andand@csd.uu.se> |
Keywords: | lex, yacc, design |
Organization: | Compilers Central |
References: | 94-10-028 |
Date: | Thu, 6 Oct 1994 13:11:02 GMT |
John Heron <heronj@smtplink.NGC.COM> writes:
> Pardon me if this question is naive. Why have a separate parser generator
> and lexical analyzer generator?
[...]
In addition to our moderator's comments one might add:
We have lots of implicit shift/reduced and sometimes reduce/reduce
conflicts in the regular portion of the grammar that corresponds to the
longest match and first match rules in Lex. Also, many languages, like C,
have difficult constructions (typedef:ed names in C) that require the
lexical analyzer to do smart things. In a common grammar this corresponds
to some form of conditional parsing rules, so we must add stuff like that.
There have been some research into lexical analyzer free parsing. For
example:
Salomon, D.J. and Cormack, G.V. Scannerless NSLR(1) Parsing of Programming
Languages, ACM SIGPLAN Conference on Programming Language Design and
Implementation, June 21-23, 1989.
Anders Andersson
andand@csd.uu.se
--
Return to the
comp.compilers page.
Search the
comp.compilers archives again.