[Python-Dev] Warning Framework (PEP 230)

Guido van Rossum guido@python.org
Mon, 11 Dec 2000 12:11:02 -0500

> > - When PyErr_Warn() returns 1, does that mean a warning has been
> >   transmuted into an exception, or some other exception occurred
> >   during the setting of the warning?  (I think I know, but the PEP
> >   could be clearer here).
> How about returning 1 for 'warning turned into exception' and -1 for 'normal
> exception' ? It would be slightly more similar to other functions if '-1'
> meant 'exception', and it would be easy to put in an if statement -- and
> still allow C code to ignore the produced error, if it wanted to.

Why would you want this?  The user clearly said that they wanted the

--Guido van Rossum (home page: http://www.python.org/~guido/)