|Lazy/tolerant parsers firstname.lastname@example.org (2004-07-13)|
|RE: Lazy/tolerant parsers email@example.com (Quinn Tyler Jackson) (2004-07-14)|
|Re: Lazy/tolerant parsers firstname.lastname@example.org (Dmitry A. Kazakov) (2004-07-14)|
|Re: Lazy/tolerant parsers email@example.com (2004-07-15)|
|Re: Lazy/tolerant parsers firstname.lastname@example.org (Dmitry A. Kazakov) (2004-07-17)|
|From:||email@example.com (Akhilesh Mritunjai)|
|Date:||13 Jul 2004 22:30:21 -0400|
|Posted-Date:||13 Jul 2004 22:30:21 EDT|
I tried searching in archives, but could not find helpful results.
I have a (Ada like) grammar for which I need to create a parser which
should be usable for code as user types (syntax highlighting, code
assist etc). So the parser should correctly deal with -
- partial sententences
- Incomplete/missing closures
Which method would you recommend to write such a parser ?
As I understand, the parser needs to flag off error conditions,
"synch" the state machine and continue parsing. However, this synching
itself will be problematic in the first place and parser may be
- User context informaction (i.e. keep an eye on what user is doing)
- Use grammar context to find next synch point
- Re-iterate several times to find the most "fitting" synch location
that makes best sense.
- Do some special juggelary at closely located error-points to avoid
iterating too much.
Right now I'm looking at eclipse's JDT java compiler/parser for hints.
Of course its too big a piece to bite at this stage, so progress is
kinda slow :)
Waiting for inputs
Return to the
Search the comp.compilers archives again.