This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author mgedmin
Recipients benjamin.peterson, mgedmin, serhiy.storchaka
Date 2014-02-15.12:15:28
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1392466530.02.0.586397729974.issue20608@psf.upfronthosting.co.za>
In-reply-to
Content
Oh, hey, PEP 3127 actually asks for a better error message than "invalid token" for this case: http://www.python.org/dev/peps/pep-3127/#tokenizer-exception-handling

So here's a tentative patch to test the waters.  I still haven't figured out how to write tests for it (is Lib/test/test_tokenize.py the right place for that?), and I haven't manually tested it either, because building CPython tip fails for me with a strange link error about _PyTraceMalloc_Init/_PyTraceMalloc_Fini.

If there's some documentation I should read about submitting CPython patches, or some IRC channel I should join, please tell me!
History
Date User Action Args
2014-02-15 12:15:30mgedminsetrecipients: + mgedmin, benjamin.peterson, serhiy.storchaka
2014-02-15 12:15:30mgedminsetmessageid: <1392466530.02.0.586397729974.issue20608@psf.upfronthosting.co.za>
2014-02-15 12:15:29mgedminlinkissue20608 messages
2014-02-15 12:15:29mgedmincreate