Is the difference that ret_obj will contain a pointer to an array when the elements are arrays and `PyObject_IsTrue(ret_obj)` will fail?

Aside, looks like this function can be called recursively during the comparison.