diff options
author | Victor Stinner <vstinner@python.org> | 2020-02-07 22:18:08 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-02-07 22:18:08 (GMT) |
commit | 60ac6ed5579f6666130fc264d3b748ee9575e3aa (patch) | |
tree | c21d06611bea34d88dd5922850223837fa6ae733 /Objects/structseq.c | |
parent | de6f38db4859f7b8fe4da4556f06c52675fff24a (diff) | |
download | cpython-60ac6ed5579f6666130fc264d3b748ee9575e3aa.zip cpython-60ac6ed5579f6666130fc264d3b748ee9575e3aa.tar.gz cpython-60ac6ed5579f6666130fc264d3b748ee9575e3aa.tar.bz2 |
bpo-39573: Use Py_SET_SIZE() function (GH-18402)
Replace direct acccess to PyVarObject.ob_size with usage of
the Py_SET_SIZE() function.
Diffstat (limited to 'Objects/structseq.c')
-rw-r--r-- | Objects/structseq.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Objects/structseq.c b/Objects/structseq.c index c86fbe5..1865e24 100644 --- a/Objects/structseq.c +++ b/Objects/structseq.c @@ -47,7 +47,7 @@ PyStructSequence_New(PyTypeObject *type) return NULL; /* Hack the size of the variable object, so invisible fields don't appear to Python code. */ - Py_SIZE(obj) = VISIBLE_SIZE_TP(type); + Py_SET_SIZE(obj, VISIBLE_SIZE_TP(type)); for (i = 0; i < size; i++) obj->ob_item[i] = NULL; |