Related articles |
---|
Parsers for run-time modifiable grammars shankar@india.hp.com (Shankar Unni) (1991-05-03) |
Re: Parsers for run-time modifiable grammars pardo@june.cs.washington.edu (1991-05-03) |
Re: Parsers for run-time modifiable grammars schoebel@bs3.informatik.uni-stuttgart.de (Thomas Schoebel) (1991-05-06) |
Re: Parsers for run-time modifiable grammars rekers@cwi.nl (1991-05-06) |
Newsgroups: | comp.compilers |
From: | rekers@cwi.nl (Jan Rekers) |
Keywords: | parse, design |
Organization: | Compilers Central |
Date: | Mon, 06 May 91 13:50:20 +0200 |
In article <771.673253499@cauvery.india.hp.com>, shankar@india.hp.com
(Shankar Unni) writes:
|> I am looking for a general-purpose parser or parser-generator tool that can
|> handle languages that allow the programmer to modify his input syntax on
|> the fly.
I am one of the authors of a paper on Incremental Parser Generation which
appeared in Sigplan Notices in june 1989:
author = {J. Heering and P. Klint and J. Rekers},
title = {{I}ncremental generation of parsers},
journal = {SIGPLAN Notices},
volume = {24},
number = {7},
pages = {179-191},
year = {1989}
An improved version of this article also appeared in IEEE-TSE december 1990:
author = {J. Heering and P. Klint and J. Rekers},
title = {{I}ncremental generation of parsers},
journal = {IEEE Transactions on Software Engineering},
volume = {16},
number = {12},
pages = {1344-1351},
year = {1990}
>From the abstract:
We describe an LR-based parser generator for arbitrary context-free grammars
that generates parsers by need and handles modifications to its input
grammar by updating the parser it has generated so far. We motivate the
need for these techniques in the context of interactive language definition
environments, present all required algorithms, and give measurements
comparing their performance with that of conventional techniques.
With this framework, we are nearly able to parse ASN.1 definitions, as that
would mainly require binding semantic actions to a rule that introduces
syntax and to the rule that leaves a scope.
There are however two problems with this approach:
- - - One should be sure that the modification of the grammar does not affect
the states which are already on the parse stack.
- - - We use the Tomita algorithm as parser, which runs several simple LR
parsers in parallel. If one of the parallel running parsers issues a
reduction of such a syntax modifying rule and the others don't, you have a
problem.
If you are interested in our approach, please do contact us. I would also be
interested in other responses you receive via the net.
Jan Rekers (rekers@cwi.nl) Centrum voor Wiskunde en Informatica (CWI)
P.O. Box 4079, 1009 AB Amsterdam, The Netherlands
--
Return to the
comp.compilers page.
Search the
comp.compilers archives again.