-
Notifications
You must be signed in to change notification settings - Fork 33
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
python.gram: SyntaxError column numbers to match cpython 3.10 #48
Conversation
SyntaxError expects 1-indexed column numbers, but tokens are 0-indexed. Fixes we-like-parsers#47
Looks great ! Thanks for taking the time to do that. Since the idea is to match CPython it may make sense to have CPython parse the same test code and validate our error syntax against the CPython one. WDYT ? |
hi everyone! I am considering to improve a few things in python.gram but don't want to tread on anybody's else's effort. Should I help out with the failing tests here? (I was wondering whether the reason for the test failures is that |
I'd definitely appreciate the help with fixing these tests! Or rather, fixing python.gram so that these tests which should pass actually do pass. (Though not sure whether @MatthieuDartiailh is currently working on it.) And we should make the comparison to Python only run on 3.10 (and maybe even a specific minor version?). Incidentally, CI should probably be updated to use 3.10.0. |
I am not working on this at the moment no. |
Done in #50 |
If nobody is working on this I will try to pick this up again soon now that my proof of concept for using pegen in a project I maintain is ready. (nucleic/enaml#474). I will probably first look into using the two passes error reporting mechanism used in the C parser. |
I didn't get around to it sorry :-( |
With #41 merged I believe everything this addressed has been fixed so closing. Feel free to reopen if the need arises. |
As suggested by @MatthieuDartiailh in this comment, this is a completion of #41 (which includes @MatthieuDartiailh original commits) that includes all the row/column tests, as well as a fix to my issue #47.