Antoine Pitrou <pit...@free.fr> added the comment: > Now, how important do you think type consistency is? when using > iterators, does one ever look at it and test its type? if this is > important, I _could_ take another look at dicts and seta and create > fresh iterators to the dicts and sets made out of the remainder of the > items, rather than iterators to lists.
I think type consistency is important if it can be achieved reasonably simply. In the dict and set case, I'm not sure you can recreate the internal table in the same order (even accross interpreter restarts). In this case, you should just check that the unpickled data is a subclass of collections.abc.Iterator. ---------- _______________________________________ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue14288> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com