summaryrefslogtreecommitdiffstats
path: root/Objects
diff options
context:
space:
mode:
authorPablo Galindo <Pablogsal@gmail.com>2019-05-31 11:07:56 (GMT)
committerGitHub <noreply@github.com>2019-05-31 11:07:56 (GMT)
commit3a46d5c293d39995dc5218bf46a7d92b16fb2a15 (patch)
tree351bf512e6ec36ea7df878c48740114c71b2ba33 /Objects
parentc7f803b08ed5211701c75f98ba9ada85d45ac155 (diff)
downloadcpython-3a46d5c293d39995dc5218bf46a7d92b16fb2a15.zip
cpython-3a46d5c293d39995dc5218bf46a7d92b16fb2a15.tar.gz
cpython-3a46d5c293d39995dc5218bf46a7d92b16fb2a15.tar.bz2
bpo-37108: Support super with methods that use positional-only arguments (GH-13695)
Diffstat (limited to 'Objects')
-rw-r--r--Objects/typeobject.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/Objects/typeobject.c b/Objects/typeobject.c
index b6d925c..da249b5 100644
--- a/Objects/typeobject.c
+++ b/Objects/typeobject.c
@@ -7807,7 +7807,7 @@ super_init(PyObject *self, PyObject *args, PyObject *kwds)
"super(): no code object");
return -1;
}
- if (co->co_argcount == 0) {
+ if (co->co_posonlyargcount + co->co_argcount == 0) {
PyErr_SetString(PyExc_RuntimeError,
"super(): no arguments");
return -1;