Skip to content
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

Refactoring: AST parser errors not enough verbose. #476

Closed
jmecosta opened this issue Apr 19, 2015 · 8 comments
Closed

Refactoring: AST parser errors not enough verbose. #476

jmecosta opened this issue Apr 19, 2015 · 8 comments

Comments

@jmecosta
Copy link
Member

We have things like this:

19:33:09.634 ERROR - Parse error at line 298 column 30:

290: (char *)s_GetTranslationCB(message));
291: else
292: result = s_CancelDialog.SetProgressTextCB(nbar, 0 );
293: }
294:
295: return result;
296: }
297:
--> int cncl_set_progress_pos(int NumberOfBar, int PercentCompleted)
299: {
300: int Result = 0;
301: static int sLastDisplayed = -1;
302:
303:
304:
305:
306: if(PercentCompleted < 0 || PercentCompleted > 100)
307: {

Have no idea why this is failing. earlier the stack trace of the parser failure was more informative than its now. Shouldnt it be better to have more info than less

@jmecosta
Copy link
Member Author

In fact the message present by the rule is even redundant when looking in web ui since those are contextualized along with source code.

@jmecosta jmecosta added this to the M 0.9.3 milestone Apr 19, 2015
@guwirth
Copy link
Collaborator

guwirth commented Apr 20, 2015

Fixed with #484?

@guwirth
Copy link
Collaborator

guwirth commented Apr 23, 2015

Improve verbosity of parser in case of error is an enhancement => next version

@guwirth guwirth removed this from the M 0.9.3 milestone Apr 23, 2015
@jmecosta
Copy link
Member Author

Ok

On Thu, Apr 23, 2015, 10:34 Günter Wirth [email protected] wrote:

Improve verbosity of parser in case of error is an enhancement => next
version


Reply to this email directly or view it on GitHub
#476 (comment).

@guwirth guwirth modified the milestone: M 0.9.4 Apr 29, 2015
@guwirth
Copy link
Collaborator

guwirth commented Jun 19, 2015

Maybe add somehow AstXmlPrinter to ParsingErrorCheck?

package com.sonar.sslr.impl.ast;
AstXmlPrinter.print(astNode)

@Bertk Bertk mentioned this issue Jul 2, 2015
@guwirth
Copy link
Collaborator

guwirth commented Jul 3, 2015

@Bertk
Copy link
Contributor

Bertk commented Jul 3, 2015

Looks promising and will definitely improve the parser error detection.

@guwirth guwirth mentioned this issue Jul 6, 2015
@guwirth guwirth removed this from the M 0.9.4 milestone Oct 19, 2015
@guwirth guwirth added this to the subsequent release milestone Oct 17, 2016
@guwirth guwirth removed this from the 0.9.8 milestone Aug 24, 2017
@guwirth guwirth changed the title AST parser errors not enough verbose. Refactoring: AST parser errors not enough verbose. Jan 21, 2018
@guwirth
Copy link
Collaborator

guwirth commented Jan 27, 2019

Not solvable.

@guwirth guwirth closed this as completed Jan 27, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Development

No branches or pull requests

3 participants