diff --git a/src/main/java/com/github/zafarkhaja/semver/util/Stream.java b/src/main/java/com/github/zafarkhaja/semver/util/Stream.java index 9d5d041..62c509f 100644 --- a/src/main/java/com/github/zafarkhaja/semver/util/Stream.java +++ b/src/main/java/com/github/zafarkhaja/semver/util/Stream.java @@ -213,6 +213,14 @@ public class Stream implements Iterable { public Iterator iterator() { return new Iterator() { + /** + * The index to indicate the current position + * of this iterator. + * + * The starting point is set to the current + * value of this stream's offset, so that it + * doesn't iterate over consumed elements. + */ private int index = offset; /**