Terry J. Reedy added the comment: Python grammar is constrained to be, I believe, LL(1). Whatever the constraint is, there are a few syntax rules that either cannot be written or would be difficult to write within the constraint. So they are checked during compilation. Can you suggest a couple of sentences you would have like to have seen, and where?
I might also note that not all exceptions raised by compile are literally 'SyntaxError's. ---------- nosy: +terry.reedy _______________________________________ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue30637> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com