This commit is contained in:
Vitor Santos Costa
2018-02-20 22:59:17 +00:00
parent e93c01f8e0
commit 3e71d171e7
9 changed files with 47 additions and 38 deletions

View File

@@ -150,7 +150,7 @@ foreign_t python_to_term(PyObject *pVal, term_t t) {
for (i = 0; i < sz; i++) {
PyObject *obj;
rc = rc && PL_unify_list(t, to, t);
if ((obj = PyList_GetItem(pVal, i - 1)) == NULL) {
if ((obj = PyList_GetItem(pVal, i)) == NULL) {
obj = Py_None;
}
rc = rc && python_to_term(obj, to);