Christian Heimes added the comment: Guido van Rossum wrote: > Guido van Rossum added the comment: > > There's C code like this: > > if (Py_Py3kWarningFlag && > PyErr_Warn(PyExc_DeprecationWarning, > "apply() not supported in 3.x") < 0) > return NULL; > > I don't know how to check for that flag in Python though -- we should > really export all flags via the sys module...
I've exposed the flag in r59204 as sys.py3kwarning. I've also added a method warnings.warnpy3k(). Christian __________________________________ Tracker <[EMAIL PROTECTED]> <http://bugs.python.org/issue1504> __________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com