Guido van Rossum wrote:
> You start with a traceback object pointing to the current frame
> object (traceback objects are distinct from frame objects,

Just out of curiosity, is it really necessary to have
a distinct traceback object? Couldn't the traceback
just be made of dead frame objects linked the opposite
way through their f_next pointers?

Seems to me it would be advantageous if raising an
exception (once it's created) could be done without
having to allocate any memory. Otherwise you could
get the situation where you're trying to raise a
MemoryError, but there's no memory to allocate a
traceback object, so you raise a MemoryError...
etc...

That might be a reason for pre-allocating the
MemoryError exception, too.

--
Greg
_______________________________________________
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

Reply via email to