Actions
Bug #19632
closedDisable external iterator for frozen enumerator
Bug #19632:
Disable external iterator for frozen enumerator
Description
Currently, methods to manipulate an external iterator like #next and #feed can be called even if a receiver of an enumerator is frozen. However, these methods change the state of an external iterator in an enumerator. Therefore, it seems a BUG to me, and these methods should raise FrozenError if the receiver is frozen.
Two years ago, this issue was mentioned in a comment.
I suggest fixing the following methods to raise FrozenError against a frozen enumerator.
Enumerator#nextEnumerator#next_valuesEnumerator#peekEnumerator#peek_valuesEnumerator#feedEnumerator#rewind
Also, even if an enumerator is frozen, it does not affect other methods for internal iterators.
Actions