summaryrefslogtreecommitdiffstats
path: root/Modules/_decimal
diff options
context:
space:
mode:
authorSerhiy Storchaka <storchaka@gmail.com>2016-04-06 06:50:03 (GMT)
committerSerhiy Storchaka <storchaka@gmail.com>2016-04-06 06:50:03 (GMT)
commitec39756960def5fdd8cb0ae191429f2f8e229f55 (patch)
treeadb8bb87ed393db602face59929660b968f452e5 /Modules/_decimal
parent72783056983f216104087b6c49d85ea273bf67c4 (diff)
parent48842714b948fa239392ddd7e207151d5fcb8bc7 (diff)
downloadcpython-ec39756960def5fdd8cb0ae191429f2f8e229f55.zip
cpython-ec39756960def5fdd8cb0ae191429f2f8e229f55.tar.gz
cpython-ec39756960def5fdd8cb0ae191429f2f8e229f55.tar.bz2
Issue #22570: Renamed Py_SETREF to Py_XSETREF.
Diffstat (limited to 'Modules/_decimal')
-rw-r--r--Modules/_decimal/_decimal.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/Modules/_decimal/_decimal.c b/Modules/_decimal/_decimal.c
index 3c2ad85..0c02d28 100644
--- a/Modules/_decimal/_decimal.c
+++ b/Modules/_decimal/_decimal.c
@@ -3439,14 +3439,14 @@ dec_as_integer_ratio(PyObject *self, PyObject *args UNUSED)
goto error;
}
- Py_SETREF(exponent, long_methods->nb_power(tmp, exponent, Py_None));
+ Py_XSETREF(exponent, long_methods->nb_power(tmp, exponent, Py_None));
Py_DECREF(tmp);
if (exponent == NULL) {
goto error;
}
if (exp >= 0) {
- Py_SETREF(numerator, long_methods->nb_multiply(numerator, exponent));
+ Py_XSETREF(numerator, long_methods->nb_multiply(numerator, exponent));
if (numerator == NULL) {
goto error;
}
@@ -3462,8 +3462,8 @@ dec_as_integer_ratio(PyObject *self, PyObject *args UNUSED)
if (tmp == NULL) {
goto error;
}
- Py_SETREF(numerator, long_methods->nb_floor_divide(numerator, tmp));
- Py_SETREF(denominator, long_methods->nb_floor_divide(denominator, tmp));
+ Py_XSETREF(numerator, long_methods->nb_floor_divide(numerator, tmp));
+ Py_XSETREF(denominator, long_methods->nb_floor_divide(denominator, tmp));
Py_DECREF(tmp);
if (numerator == NULL || denominator == NULL) {
goto error;