Boost logo

Boost :

From: Larry Evans (jcampbell3_at_[hidden])
Date: 2002-10-20 14:15:58


Juan Carlos Arevalo-Baeza wrote:

>On Sat, 19 Oct 2002 11:02:04 -0700, Carl Daniel wrote:
>
>
>
>>One concern I have, which I belive is based mostly in ignorance, is the
>>ability of a Spirit-generated parser to perform error recovery and issue
>>
>>
>>
> Try the cpp_grammar test/thingy that I have here:
>
>http://home.JCABs-Rumblings.com/ftp/SpiritX/
>
[snip]

>for display of the parser call-stack, so to speak, as in:
>
>cpp_grammar.cpp:285:9: Error: Expecting '}'
> cpp_grammar.cpp:284:5: While parsing the member declarator
> cpp_grammar.cpp:282:14: While parsing member template declaration
> cpp_grammar.cpp:275:10: While parsing template declaration
>
This looks great. What about the possibility of resynchronizing the
input for the next error message? There are some methods like skipping
all input to the next, for example, closing paren or curly brace before
restarting the parse. The purpose of these is to diagnose as many mistakes
as possible. Does anybody have any ideas about doing this next?


Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk