-
Notifications
You must be signed in to change notification settings - Fork 15
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Implementation of error recovery? #2
Comments
Sorry for the delay with the answer. Core of YAEP source code is more than 10 years old. It is hard for me to remember the details. In brief, it is a gready search technique with removing searches which are already known to result in worst cost recovery. One search step is the following
As I remember the algorithm does permit several Building abstract tree and error recovery are the most complicated parts of YAEP. Actually I wanted to write an article about the algorithms when I wrote YAEP but I am not in a research business and hate to be rejected by some conference. If that time we had arxiv.org, I defintely worte the article for it. Still I am considering it but I have no time for this as it also requires a deep analysis what I wrote in YAEP. |
@vnmakarov Many thanks for your response! A few question regarding some details just to make sure I understood them correctly:
|
Yes. But as we can have nested error recovery steps, we go back to the closest state but not further the state with .error of the parent error recovery step
Successful matching N tokens means the end of error recovery. Shifting less than N tokens during an error recovery step we can have new states with .error. So in this case we can start nested error recovery steps inside of given error recovery step.
Sorry, I wrote the opposite "does permit multiple error shift". As I wrote during one error recovery step we can have nested error recovery steps. It means possibility of multiple shifts by I should acknowledge the algorithm is complicated but it produces minimal cost error recovery when we permits more one shift by Inserting new tokens in some cases might result in a better error recovery (with smaller error recovery cost) but my algorithm does not do it. |
Hi,
This project looks very interesting to me as I'm trying to build earley parsers with different strategies. @vnmakarov I was wondering if it's possible for you to briefly mention how the error handling algorithm works? Or a few pointers to where related code relies will also be useful!
Great project!
Thanks and Best!
The text was updated successfully, but these errors were encountered: