Skip to content

Commit

Permalink
minor fixups
Browse files Browse the repository at this point in the history
  • Loading branch information
Fidget-Spinner committed Mar 27, 2024
1 parent 868b78e commit 6024a4b
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 4 deletions.
5 changes: 4 additions & 1 deletion Objects/listobject.c
Original file line number Diff line number Diff line change
Expand Up @@ -3206,7 +3206,10 @@ _PyList_FromTaggedArraySteal(_Py_TaggedObject const *src, Py_ssize_t n)
}

PyObject **dst = list->ob_item;
memcpy(dst, src, n * sizeof(PyObject *));
for (Py_ssize_t i = 0; i < n; i++) {
PyObject *item = Py_CLEAR_TAG(src[i]);
dst[i] = item;
}

return (PyObject *)list;
}
Expand Down
2 changes: 1 addition & 1 deletion Python/bytecodes.c
Original file line number Diff line number Diff line change
Expand Up @@ -1684,7 +1684,7 @@ dummy_func(
assert(PyTuple_GET_SIZE(keys) == (Py_ssize_t)oparg);
map = _PyDict_FromTaggedItems(
&PyTuple_GET_ITEM(keys, 0), 1,
(PyObject **)(values), 1, oparg);
values, 1, oparg);
DECREF_INPUTS();
ERROR_IF(map == NULL, error);
}
Expand Down
2 changes: 1 addition & 1 deletion Python/executor_cases.c.h

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion Python/generated_cases.c.h

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit 6024a4b

Please sign in to comment.