summaryrefslogtreecommitdiffstats
path: root/Objects/setobject.c
diff options
context:
space:
mode:
authorSerhiy Storchaka <storchaka@gmail.com>2017-06-08 11:41:19 (GMT)
committerGitHub <noreply@github.com>2017-06-08 11:41:19 (GMT)
commit6cca5c8459cc439cb050010ffa762a03859d3051 (patch)
tree9c144fde07123ff6c9d6f87a2a2b3d42883630d4 /Objects/setobject.c
parent865de27dd79571a4a5c7a7d22a07fb909c4a9f8e (diff)
downloadcpython-6cca5c8459cc439cb050010ffa762a03859d3051.zip
cpython-6cca5c8459cc439cb050010ffa762a03859d3051.tar.gz
cpython-6cca5c8459cc439cb050010ffa762a03859d3051.tar.bz2
bpo-30592: Fixed error messages for some builtins. (#1996)
Error messages when pass keyword arguments to some builtins that don't support keyword arguments contained double parenthesis: "()()". The regression was introduced by bpo-30534.
Diffstat (limited to 'Objects/setobject.c')
-rw-r--r--Objects/setobject.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/Objects/setobject.c b/Objects/setobject.c
index a9dba31..2347b9d 100644
--- a/Objects/setobject.c
+++ b/Objects/setobject.c
@@ -1083,7 +1083,7 @@ frozenset_new(PyTypeObject *type, PyObject *args, PyObject *kwds)
{
PyObject *iterable = NULL, *result;
- if (type == &PyFrozenSet_Type && !_PyArg_NoKeywords("frozenset()", kwds))
+ if (type == &PyFrozenSet_Type && !_PyArg_NoKeywords("frozenset", kwds))
return NULL;
if (!PyArg_UnpackTuple(args, type->tp_name, 0, 1, &iterable))
@@ -2006,7 +2006,7 @@ set_init(PySetObject *self, PyObject *args, PyObject *kwds)
{
PyObject *iterable = NULL;
- if (!_PyArg_NoKeywords("set()", kwds))
+ if (!_PyArg_NoKeywords("set", kwds))
return -1;
if (!PyArg_UnpackTuple(args, Py_TYPE(self)->tp_name, 0, 1, &iterable))
return -1;