Terry Reedy wrote:
> I would agree... but...
> The problem is that code that uses a function hardly cares whether an
> exception that replaces the normal return is raised explicitly, by a
> syntax operation (and these are not yet completely documented, though
> perhaps they should be), or by a function called within the function.

I often read that argument that info on thrown exceptions does not matter in Python, but I beg to differ. Just as a simple and well-known example, it is absolutely important to know that the str.index() method throws a ValueError if nothing is found, while the str.find() method should never throw a ValueError.

-- Christoph
--
http://mail.python.org/mailman/listinfo/python-list

Reply via email to