summaryrefslogtreecommitdiff
path: root/Python
diff options
context:
space:
mode:
authorVictor Stinner <victor.stinner@gmail.com>2016-09-09 17:40:22 -0700
committerVictor Stinner <victor.stinner@gmail.com>2016-09-09 17:40:22 -0700
commita9efb2f56eb6bcb97cebfadf1e778b4cb979357f (patch)
treeab942c23afa123480faca8207c99c53e804eceed /Python
parent78601a38c22ba1f09104e2562a10a94cbd36f5f0 (diff)
downloadcpython-git-a9efb2f56eb6bcb97cebfadf1e778b4cb979357f.tar.gz
Add METH_FASTCALL calling convention
Issue #27810: Add a new calling convention for C functions: PyObject* func(PyObject *self, PyObject **args, Py_ssize_t nargs, PyObject *kwnames); Where args is a C array of positional arguments followed by values of keyword arguments. nargs is the number of positional arguments, kwnames are keys of keyword arguments. kwnames can be NULL.
Diffstat (limited to 'Python')
-rw-r--r--Python/getargs.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/Python/getargs.c b/Python/getargs.c
index 0854cc45e6..5e85ea4fc1 100644
--- a/Python/getargs.c
+++ b/Python/getargs.c
@@ -1992,8 +1992,9 @@ vgetargskeywordsfast(PyObject *args, PyObject *keywords,
return cleanreturn(0, &freelist);
}
}
- else if (i < nargs)
+ else if (i < nargs) {
current_arg = PyTuple_GET_ITEM(args, i);
+ }
if (current_arg) {
msg = convertitem(current_arg, &format, p_va, flags,