Looks like this could be re-written to be a regular while loop with the `$this->pos >= $this->length` as the conditional instead of `true`?

Do/while loops are a bit hard to read, and in this case it doesn't seem necessary because condition is just `true` anyway (which I'm aware I used myself in the same class, but seems better to avoid if there's a natural way to do so).