> >> > I'm assuming a fair number of people have been following this already > >> > in the checkins list; I think it's ready for review on python-dev: > >> > > >> > http://www.python.org/peps/pep-0307.html > >> > >> Am I understanding correctly that this means the bozo __getstate__ > >> method for classes with __slots__ can go away? > > > > Alas, not, for backwards compatibility reasons. Pickle protocols 0 > > and 1 can't be changed, and their pickles must be acceptable for > > Python 2.2, whose unpickling code doesn't know how to deal with slots. > > (Ditto for the semi-bozo __reduce__ inherited from object.) > > OK, but I'm guessing classes with __slots__ will pickle without > intervention under protocol 2? Just curious, no big worries. Yes. > > I could try to remove the bozo __getstate__ and move the check into > > the pickling code; that would certainly remove a wart from the code > > there. > > Anything to get code out of typeobject.c <wink>. I'll give that a try right now. --Guido van Rossum (home page: http://www.python.org/~guido/)
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4