From: Sanyam Khurana <8039608+CuriousLearner@users.noreply.github.com> Date: Mon, 13 Nov 2017 21:49:26 +0000 (+0530) Subject: bpo-16055: Fixes incorrect error text for int('1', base=1000) (#4376) X-Git-Tag: v3.7.0a3~174 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=28b624825eb92cb8c96fbf8da267d8d14a61a841;p=python bpo-16055: Fixes incorrect error text for int('1', base=1000) (#4376) * bpo-16055: Fixes incorrect error text for int('1', base=1000) * bpo-16055: Address review comments --- diff --git a/Objects/longobject.c b/Objects/longobject.c index 74371557cd..c3dc59ee9e 100644 --- a/Objects/longobject.c +++ b/Objects/longobject.c @@ -4808,7 +4808,7 @@ long_new_impl(PyTypeObject *type, PyObject *x, PyObject *obase) return NULL; if ((base != 0 && base < 2) || base > 36) { PyErr_SetString(PyExc_ValueError, - "int() base must be >= 2 and <= 36"); + "int() base must be >= 2 and <= 36, or 0"); return NULL; }