"J. Clifford Dyer" <[EMAIL PROTECTED]> wrote: >> I think you are being a little bit unfair here: help(len) says: >> >> len(...) >> len(object) -> integer >> >> Return the number of items of a sequence or mapping. >> >> which implies that the argument to len has the name 'object' >> (although in fact it doesn't have a name). The OP was simply asking >> about the difference in calling conventions, not proposing to write >> code using 'object' as the argument name. > > Hmm.... To my mind, that just implies that the *type* of the expected > input is an object. Just like the "-> integer" tells you that the > type of the output is an integer. If the documentation read > "len(s=object) -> integer", then I would expect a keyword argument s > typed as an object. >
How do you interpret: >>> help(__import__) Help on built-in function __import__ in module __builtin__: __import__(...) __import__(name, globals={}, locals={}, fromlist=[], level=-1) -> module ... >>> help(int) Help on class int in module __builtin__: class int(object) | int(x[, base]) -> integer ... Can you find any case (other than a single parameter identified as 'object') where you can interpret the help string as telling you the types of the parameters? -- http://mail.python.org/mailman/listinfo/python-list