diff options
Diffstat (limited to 'Modules/_sqlite/row.c')
-rw-r--r-- | Modules/_sqlite/row.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/Modules/_sqlite/row.c b/Modules/_sqlite/row.c index 64dfd06..d863643 100644 --- a/Modules/_sqlite/row.c +++ b/Modules/_sqlite/row.c @@ -142,8 +142,7 @@ PyObject* pysqlite_row_subscript(pysqlite_Row* self, PyObject* idx) return NULL; } else if (PySlice_Check(idx)) { - PyErr_SetString(PyExc_ValueError, "slices not implemented, yet"); - return NULL; + return PyObject_GetItem(self->data, idx); } else { PyErr_SetString(PyExc_IndexError, "Index must be int or string"); @@ -159,7 +158,7 @@ Py_ssize_t pysqlite_row_length(pysqlite_Row* self, PyObject* args, PyObject* kwa PyObject* pysqlite_row_keys(pysqlite_Row* self, PyObject* args, PyObject* kwargs) { PyObject* list; - int nitems, i; + Py_ssize_t nitems, i; list = PyList_New(0); if (!list) { |