Actually it does all work. I wrote some tests that verify it. I think
my first question about index and cur works out because both are set
to 0 -- and 0 is correct as the starting value of an array offset and
index. And in the other case I believe it's intended that the two
values are the current and next values, respectively.

Nevertheless let me post a patch that rearranges these
Iterator/Element implementations in a way that is perhaps more
consistent across the three classes in naming and structure. I think
there are a few opportunities for streamlining too -- for example
these static inner classes are taking a reference to the enclosing
class, when making them non-static gets you that for free. (There's
still a reference there, just synthetic.)

Reply via email to