|syntax-directed editing email@example.com (Alexander Stippler) (2000-08-27)|
|Re: syntax-directed editing firstname.lastname@example.org (Quinn Tyler Jackson) (2000-09-07)|
|Re: syntax-directed editing maratb@CS.Berkeley.EDU (Marat Boshernitsan) (2000-09-08)|
|Re: syntax-directed editing email@example.com (2000-09-08)|
|From:||Marat Boshernitsan <maratb@CS.Berkeley.EDU>|
|Date:||8 Sep 2000 01:56:13 -0400|
|Organization:||University of California at Berkeley|
Alexander Stippler <firstname.lastname@example.org> writes:
> How can I manage this rebuilding as little as possible of the AST and
> how can I do it at all?
You should take a look at the Harmonia project
(http://www.cs.berkeley.edu/~harmonia). We've been working on something
like this for a while (actually, we reparse on virtually every
keystroke) and we have a fairly general solution to the incremental
parsing problem (follow the "publications" link and look for Tim
> Do you know some introducing papers or other
> materials on this topic?
There's been a lot of work on syntax directed editors done in the 80s.
Take a look at the reference section of Tim Wagner's work and you will
find a lot of useful references. One of the biggest caveats is getting
the user model "right", so that the user does not even suspect that
there's an AST underlying the textual representation he/she sees on the
Hope this helps,
Marat Boshernitsan, UC Berkeley
Our esteemed moderator writes:
> that incrementally updated the parse tree. If the text is stored in a
> tokenized form, I'd guess that reparsing is fast enough that it's
> not worth a lot of work to avoid. -John]
This is all true unless there's information associated with internal
AST nodes rather than leaves (tokens) and that cannot be (easily)
recomputed. An example would be profiling data attached to function
declarations. In this case it is worth the trouble to preserve as
much AST structure as possible across parses.
Return to the
Search the comp.compilers archives again.