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

Fixed ParseBytes and ParseFile by adding agclearerrors in C #66

Merged
merged 5 commits into from
Mar 21, 2023

Conversation

denk0403
Copy link
Contributor

@denk0403 denk0403 commented Feb 13, 2023

A fix for the bug described by issue #60.

In summary, this PR introduces agclearerrors() in the C code, which closes and resets the output file for error reporting. In the ccall package, a binding is created via Agclearerrors() function.

ParseBytes() and ParseFile() in the cgraph package now call Agclearerrors() before reading and parsing the buffer to ensure there are no extraneous errors left over, and that the call to Aglasterr() returns only new errors produced by parsing.

@denk0403 denk0403 changed the title Fixed ParseBytes by adding a agclearerrors in C Fixed ParseBytes and ParseFile by adding a agclearerrors in C Feb 13, 2023
@denk0403 denk0403 changed the title Fixed ParseBytes and ParseFile by adding a agclearerrors in C Fixed ParseBytes and ParseFile by adding agclearerrors in C Feb 13, 2023
@goccy
Copy link
Owner

goccy commented Mar 19, 2023

Thank you for your contribution ! I've commented

@denk0403
Copy link
Contributor Author

The tests should pass for Go version 1.15 now!

@denk0403 denk0403 requested a review from goccy March 21, 2023 02:48
@goccy goccy merged commit 865af03 into goccy:master Mar 21, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants