Adam Tauno Williams wrote:
Yes, it certainly does.  Not that you'll get many Pythonistas to confess
to that fact.  Somehow those who brag about the readability and
expressiveness of source code just cannot admit that:

class.method(sting name, int count)
- is *obviously* more expressive than -

class.method(name, count)

class.method(string name, int count):
"""Return the cap'tain's age.

   name: a string giving the name of the cap'tain daughter
count: an int giving the number of fingers left in the cap'tain right hand
"""

In python, attributes/parameters have no type (but you know that). By specifying them in the method signature, you're just duplicating the information hold in the docstring.

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

Reply via email to