Ram Rachum added the comment:

David, as a more generalized solution: Do you think it's possible to make some 
kind of mechanism in Python that would change the way that an exception is 
constructed based on whether it's used for control flow or not? I know that 
it's a bit far-fetched, but if we could figure out a way to do that, it'll free 
us from having to serve two masters at the same time (one of them being clear 
error messages, the other being fast times to create an exception.)

That way we could make the exceptions have very helpful messages when a person 
will see them, but keep them fast when a person won't. It's a shot in the dark 
but if someone has an idea for how to do it, that'd be cool. Another 
possibility is to make the -O flag do this switch, though there are problems 
with that too.

----------

_______________________________________
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue21911>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to