Python 2.5.1 (r251:54863, Apr 18 2007, 08:51:08) [MSC v.1310 32 bit (Intel)] on win32 Type "help", "copyright", "credits" or "license" for more information. >>> import inspect >>> inspect.getargspec(list.__dict__["__getitem__"]) Traceback (most recent call last): File "", line 1, in File "C:\Program Files\Python25\lib\inspect.py", line 743, in getargspec raise TypeError('arg is not a Python function') TypeError: arg is not a Python function >>> inspect.getargspec(list.remove) Traceback (most recent call last): File "", line 1, in File "C:\Program Files\Python25\lib\inspect.py", line 743, in getargspec raise TypeError('arg is not a Python function') TypeError: arg is not a Python function >>> list.remove >>> inspect.getargspec(len) Traceback (most recent call last): File "", line 1, in File "C:\Program Files\Python25\lib\inspect.py", line 743, in getargspec raise TypeError('arg is not a Python function') TypeError: arg is not a Python function >>> type(len) >>> def mymethod(x): ... print x ... >>> inspect.getargspec(mymethod) (['x'], None, None, None) >>> type(mymethod) >>> class MyClass: ... def my_method(self, x): ... print x ... >>> inspect.getargspec(MyClass.my_method) (['self', 'x'], None, None, None) >>> MyClass.my_method >>> m = MyClass() >>> inspect.getargspec(m.my_method) (['self', 'x'], None, None, None) >>> m.my_method > >>> >>> help(list.__getitem__) Help on method_descriptor: __getitem__(...) x.__getitem__(y) <==> x[y] >>> help(list.remove) Help on method_descriptor: remove(...) L.remove(value) -- remove first occurrence of value >>> help(len) Help on built-in function len in module __builtin__: len(...) len(object) -> integer Return the number of items of a sequence or mapping. >>>