Add message to exception.
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/collections/trunk@1546206 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
393fa5df92
commit
59899e1c82
|
@ -151,7 +151,7 @@ public class PeekingIterator<E> implements Iterator<E> {
|
|||
*/
|
||||
public void remove() {
|
||||
if (slotFilled) {
|
||||
throw new IllegalStateException();
|
||||
throw new IllegalStateException("peek() or element() called before remove()");
|
||||
}
|
||||
iterator.remove();
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue