From e82881cea7a0cab6145a2071b08665c8e9ec9d31 Mon Sep 17 00:00:00 2001 From: Guido van Rossum Date: Tue, 15 Jul 2014 12:29:11 -0700 Subject: Fix getargspec() doctring (varkw -> keywords). --- Lib/inspect.py | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/Lib/inspect.py b/Lib/inspect.py index b9cdcc2..f6b5bad 100644 --- a/Lib/inspect.py +++ b/Lib/inspect.py @@ -914,10 +914,9 @@ ArgSpec = namedtuple('ArgSpec', 'args varargs keywords defaults') def getargspec(func): """Get the names and default values of a function's arguments. - A tuple of four things is returned: (args, varargs, varkw, defaults). - 'args' is a list of the argument names. - 'args' will include keyword-only argument names. - 'varargs' and 'varkw' are the names of the * and ** arguments or None. + A tuple of four things is returned: (args, varargs, keywords, defaults). + 'args' is a list of the argument names, including keyword-only argument names. + 'varargs' and 'keywords' are the names of the * and ** arguments or None. 'defaults' is an n-tuple of the default values of the last n arguments. Use the getfullargspec() API for Python 3 code, as annotations -- cgit v0.12