:internal: next iterator function seems to work now