Commit a1433fed authored by Antoine Pitrou's avatar Antoine Pitrou

Remove tab characters

parent 682d94c1
...@@ -2360,21 +2360,21 @@ PyType_FromSpec(PyType_Spec *spec) ...@@ -2360,21 +2360,21 @@ PyType_FromSpec(PyType_Spec *spec)
return NULL; return NULL;
res->ht_name = PyUnicode_FromString(spec->name); res->ht_name = PyUnicode_FromString(spec->name);
if (!res->ht_name) if (!res->ht_name)
goto fail; goto fail;
res->ht_type.tp_name = _PyUnicode_AsString(res->ht_name); res->ht_type.tp_name = _PyUnicode_AsString(res->ht_name);
if (!res->ht_type.tp_name) if (!res->ht_type.tp_name)
goto fail; goto fail;
res->ht_type.tp_basicsize = spec->basicsize; res->ht_type.tp_basicsize = spec->basicsize;
res->ht_type.tp_itemsize = spec->itemsize; res->ht_type.tp_itemsize = spec->itemsize;
res->ht_type.tp_flags = spec->flags | Py_TPFLAGS_HEAPTYPE; res->ht_type.tp_flags = spec->flags | Py_TPFLAGS_HEAPTYPE;
for (slot = spec->slots; slot->slot; slot++) { for (slot = spec->slots; slot->slot; slot++) {
if (slot->slot >= sizeof(slotoffsets)/sizeof(slotoffsets[0])) { if (slot->slot >= sizeof(slotoffsets)/sizeof(slotoffsets[0])) {
PyErr_SetString(PyExc_RuntimeError, "invalid slot offset"); PyErr_SetString(PyExc_RuntimeError, "invalid slot offset");
goto fail; goto fail;
} }
*(void**)(res_start + slotoffsets[slot->slot]) = slot->pfunc; *(void**)(res_start + slotoffsets[slot->slot]) = slot->pfunc;
/* need to make a copy of the docstring slot, which usually /* need to make a copy of the docstring slot, which usually
points to a static string literal */ points to a static string literal */
...@@ -2382,7 +2382,7 @@ PyType_FromSpec(PyType_Spec *spec) ...@@ -2382,7 +2382,7 @@ PyType_FromSpec(PyType_Spec *spec)
size_t len = strlen(slot->pfunc)+1; size_t len = strlen(slot->pfunc)+1;
char *tp_doc = PyObject_MALLOC(len); char *tp_doc = PyObject_MALLOC(len);
if (tp_doc == NULL) if (tp_doc == NULL)
goto fail; goto fail;
memcpy(tp_doc, slot->pfunc, len); memcpy(tp_doc, slot->pfunc, len);
res->ht_type.tp_doc = tp_doc; res->ht_type.tp_doc = tp_doc;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment