Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
C
cpython
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
cpython
Commits
62816345
Commit
62816345
authored
Sep 12, 2007
by
Georg Brandl
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Document inspect.getfullargspec(). Fixes #1121.
parent
5f1a0611
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
25 additions
and
4 deletions
+25
-4
Doc/library/inspect.rst
Doc/library/inspect.rst
+25
-4
No files found.
Doc/library/inspect.rst
View file @
62816345
...
...
@@ -376,10 +376,31 @@ Classes and functions
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 (it may contain nested lists). *varargs* and *varkw* are the
names of the ``*`` and ``**`` arguments or ``None``. *defaults* is a tuple of
default argument values or None if there are no default arguments; if this tuple
has *n* elements, they correspond to the last *n* elements listed in *args*.
the argument names. *varargs* and *varkw* are the names of the ``*`` and
``**`` arguments or ``None``. *defaults* is a tuple of default argument
values or None if there are no default arguments; if this tuple has *n*
elements, they correspond to the last *n* elements listed in *args*.
.. deprecated:: 3.0
Use :func:`getfullargspec` instead, which provides information about
keyword-only arguments.
.. function:: getfullargspec(func)
Get the names and default values of a function's arguments. A tuple of seven
things is returned:
``(args, varargs, varkw, defaults, kwonlyargs, kwonlydefaults, annotations)``
*args* is a list of the argument names. *varargs* and *varkw* are the names
of the ``*`` and ``**`` arguments or ``None``. *defaults* is an n-tuple of
the default values of the last n arguments. *kwonlyargs* is a list of
keyword-only argument names. *kwonlydefaults* is a dictionary mapping names
from kwonlyargs to defaults. *annotations* is a dictionary mapping argument
names to annotations.
The first four items in the tuple correspond to :func:`getargspec`.
.. function:: getargvalues(frame)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment