Skip to content
Merged
Changes from 4 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions Modules/arraymodule.c
Original file line number Diff line number Diff line change
Expand Up @@ -3063,11 +3063,13 @@ array_new(PyTypeObject *type, PyObject *args, PyObject *kwds)
PySequence_GetItem(initial, i);
if (v == NULL) {
Py_DECREF(a);
Py_XDECREF(it);
return NULL;
Comment on lines 3067 to 3069
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is a common part for most cleanups. You can add a label and use goto statements in other places.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No need to refactor now.

}
if (setarrayitem(a, i, v) != 0) {
Py_DECREF(v);
Py_DECREF(a);
Py_XDECREF(it);
return NULL;
}
Py_DECREF(v);
Expand Down
Loading