Steven D'Aprano wrote:

> But an upside is that it would enable more useful error messages, at least
> sometimes. Here's some trivial pseudo-code:
> 
> def foo(a):
>     assert len(a) > 10, "%s is too short" % a.__name__
> 
> y = "hello"
> foo(y)
> 
> would display "AssertionError: y is too short".

why not "a is too short" ?

or for that matter, "x is to short" ?

</F>

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

Reply via email to