On Sep 19, 9:22 pm, MRAB <pyt...@mrabarnett.plus.com> wrote:
> The point is that it's sometimes a good idea to do a cheap check first
> before attempting an operation that's 'expensive' even when it fails.

Strongly agree. Furthermore, with LBYL it's often easier to give a
user clearer error messages for common usage errors, rather than
waiting for an exception in a much lower-level place where it's less
clear to them what the cause is.
-- 
http://mail.python.org/mailman/listinfo/python-list

Reply via email to