Separation of parsing from AST construction and attribute evaluation

ralphpboland@yahoo.com (Ralph Boland)
2 Oct 2004 01:14:11 -0400

          From comp.compilers

Related articles
Separation of parsing from AST construction and attribute evaluation ralphpboland@yahoo.com (2004-10-02)
RE: Separation of parsing from AST construction and attribute evaluati quinn-j@shaw.ca (Quinn Tyler Jackson) (2004-10-02)
Re: Separation of parsing from AST construction and attribute evaluati rich@pennware.com (Richard Pennington) (2004-10-02)
Re: Separation of parsing from AST construction and attribute evaluati cfc@shell01.TheWorld.com (Chris F Clark) (2004-10-04)
Re: Separation of parsing from AST construction and attribute evaluati rbates@southwind.net (Rodney M. Bates) (2004-10-09)
| List of all articles for this month |
From: ralphpboland@yahoo.com (Ralph Boland)
Newsgroups: comp.compilers
Date: 2 Oct 2004 01:14:11 -0400
Organization: http://groups.google.com
Keywords: parse
Posted-Date: 02 Oct 2004 01:14:10 EDT

I am designing a parser generator tool and I want it to work such that
the specification for parsing an input language is entirely
implementation language independant. Thus the same specification may
be used to construct a parser in several different implementation
languages.


To do this I will have an input language specification split over
several files.


The first file will specify how to parse the input language and will
contain no information on abstract syntax tree (AST) construction or
on attribute evaluation. It will be completely implementation language
independant.


The part of the language specification involving AST construction,
attribute evaluation, and possibly other aspects of compiler
construction specification are to be placed in one or more files
(distinct from the file for parsing specification). These files are
meant to be as implementation language independant as possible but
here I expect complete independance to be difficult or impossble to
achieve.


I am interested in looking at parser generator tools that also use
multiple files in this way.


CAN ANYONE POINT ME TO PARSER GENERATOR TOOLS THAT SEPARATE
IMPLEMENTATION LANGUAGE FROM INPUT LANGUAGE SPECIFICATION?


(I believe Jaccie does this; hopefully there are others.)


IT WOULD BE GREAT IF ANYONE CAN
POINT ME TO PAPERS ON THIS SUBJECT.


Thanks


Ralph Boland
[Until yacc came along, parser generators tended to take a grammar,
create the parse tables, and put them in a file. It was up to you
to remember what rule had what number and manually match it up with
the action code. It was a huge convenience when yacc let you put
the grammar and the code in one file and have it write the code
to call the action for each rule. -John]



Post a followup to this message

Return to the comp.compilers page.
Search the comp.compilers archives again.