Getting nearer to a working recursive iterator