Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit fa33163

Browse files
committed
Discard unused function.
1 parent ff0ffb3 commit fa33163

1 file changed

Lines changed: 0 additions & 34 deletions

File tree

Objects/typeobject.c

Lines changed: 0 additions & 34 deletions
Original file line numberDiff line numberDiff line change
@@ -1582,40 +1582,6 @@ valid_identifier(PyObject *s)
15821582
return 1;
15831583
}
15841584

1585-
/* Replace Unicode objects in slots. */
1586-
1587-
static PyObject *
1588-
_unicode_to_string(PyObject *slots, Py_ssize_t nslots)
1589-
{
1590-
PyObject *tmp = NULL;
1591-
PyObject *slot_name, *new_name;
1592-
Py_ssize_t i;
1593-
1594-
for (i = 0; i < nslots; i++) {
1595-
if (PyUnicode_Check(slot_name = PyTuple_GET_ITEM(slots, i))) {
1596-
if (tmp == NULL) {
1597-
tmp = PySequence_List(slots);
1598-
if (tmp == NULL)
1599-
return NULL;
1600-
}
1601-
new_name = _PyUnicode_AsDefaultEncodedString(slot_name,
1602-
NULL);
1603-
if (new_name == NULL) {
1604-
Py_DECREF(tmp);
1605-
return NULL;
1606-
}
1607-
Py_INCREF(new_name);
1608-
PyList_SET_ITEM(tmp, i, new_name);
1609-
Py_DECREF(slot_name);
1610-
}
1611-
}
1612-
if (tmp != NULL) {
1613-
slots = PyList_AsTuple(tmp);
1614-
Py_DECREF(tmp);
1615-
}
1616-
return slots;
1617-
}
1618-
16191585
/* Forward */
16201586
static int
16211587
object_init(PyObject *self, PyObject *args, PyObject *kwds);

0 commit comments

Comments
 (0)