Modify SOL_LIST_ITR to keep the current and index values local to
prevent bugs while performing nested iterations.