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

[FEATURE]: Build a rudimentary error listener that collects parser and semantic errors #340

Closed
1 task done
jimidle opened this issue May 10, 2024 · 0 comments · Fixed by #346
Closed
1 task done
Labels
enhancement New feature or request

Comments

@jimidle
Copy link
Contributor

jimidle commented May 10, 2024

Is there an existing issue for this?

  • I have searched the existing issues

Problem statement

The standard output for ANTLR4 recognizers is just to print a basic message to standard err. It would be useful to collect these, and provide rudimentary additional information such as number of errors. This will enhance testing and also allow the builders and any other walkers to provide semantic errors or errors about inability to convert code (linting down the line, perhaps).

This will make it easier for test specifications to stop if parsing errors occur, amongst other things.

Proposed Solution

A quick and dirty collector will be written that collects errors without doing anything too fancy. Maybe go as far as printing the source line in error with a carat, but such things can always be added later.

Additional Context

No response

@jimidle jimidle added the enhancement New feature or request label May 10, 2024
github-merge-queue bot pushed a commit that referenced this issue May 22, 2024
…mantic and linting errors (#346)

A simple error collector is created, which allows determination of
errors in test code and makes that a little easier. In the future, it
can be expanded to support different types of errors such as semantic
errors.

Closes: #340
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
1 participant