summaryrefslogtreecommitdiffstats
path: root/Doc/library/dis.rst
diff options
context:
space:
mode:
authorGeorg Brandl <georg@python.org>2013-10-12 16:41:23 (GMT)
committerGeorg Brandl <georg@python.org>2013-10-12 16:41:23 (GMT)
commit3cb26b77b646b09f6f511a5dbd53770e9ffb9c93 (patch)
treeb7866a22752451a9969d285327638d2701310997 /Doc/library/dis.rst
parent32b2c62db43296571ee7ebefd845516106c5abea (diff)
parentc96ef1f0eddb93436038b7a35c3ae6b13824641a (diff)
downloadcpython-3cb26b77b646b09f6f511a5dbd53770e9ffb9c93.zip
cpython-3cb26b77b646b09f6f511a5dbd53770e9ffb9c93.tar.gz
cpython-3cb26b77b646b09f6f511a5dbd53770e9ffb9c93.tar.bz2
merge with 3.3
Diffstat (limited to 'Doc/library/dis.rst')
-rw-r--r--Doc/library/dis.rst15
1 files changed, 11 insertions, 4 deletions
diff --git a/Doc/library/dis.rst b/Doc/library/dis.rst
index a546f68..40aaeeb 100644
--- a/Doc/library/dis.rst
+++ b/Doc/library/dis.rst
@@ -846,10 +846,17 @@ the more significant byte last.
.. opcode:: MAKE_FUNCTION (argc)
- Pushes a new function object on the stack. TOS is the
- :term:`qualified name` of the function; TOS1 is the code associated with
- the function. The function object is defined to have *argc* default parameters,
- which are found below TOS1.
+ Pushes a new function object on the stack. From bottom to top, the consumed
+ stack must consist of
+
+ * ``argc & 0xFF`` default argument objects in positional order
+ * ``(argc >> 8) & 0xFF`` pairs of name and default argument, with the name
+ just below the object on the stack, for keyword-only parameters
+ * ``(argc >> 16) & 0x7FFF`` parameter annotation objects
+ * a tuple listing the parameter names for the annotations (only if there are
+ ony annotation objects)
+ * the code associated with the function (at TOS1)
+ * the :term:`qualified name` of the function (at TOS)
.. opcode:: MAKE_CLOSURE (argc)