Commit 60f7d3b5 authored by Stefan Behnel's avatar Stefan Behnel

Add missing cast to avoid a compiler warning on platforms where char is unsigned.

parent 2d1ca079
......@@ -746,7 +746,7 @@ static CYTHON_INLINE char __Pyx_PyBytes_GetItemInt(PyObject* bytes, Py_ssize_t i
Py_ssize_t size = PyBytes_GET_SIZE(bytes);
if (unlikely(index >= size) | ((index < 0) & unlikely(index < -size))) {
PyErr_SetString(PyExc_IndexError, "string index out of range");
return -1;
return (char) -1;
}
}
if (index < 0)
......
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