On Thu, Oct 9, 2008 at 5:37 PM, Greg Ewing <[EMAIL PROTECTED]> wrote: > Amaury Forgeot d'Arc wrote: > >> But this is already the case, and the reason why there are three >> variable to describe an exception: type, value and traceback. > > Yes, but you only get one object for the value, which means > at least allocating a tuple if you want to be able to report > something like "AttributeError: 'fooblat' object has no > attribute 'asdf'". > > I'm thinking about a C api that would let you supply multiple > pre-existing values without having to allocate anything. > Not sure exactly how it would work, though. > > Also, what about Py3? Has the type/value separation gone away > completely, or is it still there at the C level? >
It's still there. I think the major C changes for exceptions was adding support for the three new attributes (__traceback__, __context__, and __cause__). -Brett _______________________________________________ Python-Dev mailing list Python-Dev@python.org http://mail.python.org/mailman/listinfo/python-dev Unsubscribe: http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com