Emanuel Barry added the comment: Thank you Nick for the useful feedback! I think that a subclass of DeprecationWarning and SyntaxWarning would be a good idea; I'll play around with that.
As far as when the warning should occur, I agree that erroring out at the compile step isn't optimal, however (AFAIK) strings aren't checked again once they've been created; they're assumed to be correct (and checking them at runtime would presumably add a performance hit to *all* strings, which I think is too big a price to pay). On the other hand, a way to ignore invalid escapes in certain files could be considered, but we need to be somewhat careful since some people might choose to silence all warnings, thus defeating the purpose. ---------- _______________________________________ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue28128> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com