[Python-checkins] python/nondist/peps pep-0307.txt,1.21,1.22
gvanrossum@users.sourceforge.net
gvanrossum@users.sourceforge.net
Mon, 10 Feb 2003 13:34:32 -0800
Update of /cvsroot/python/python/nondist/peps
In directory sc8-pr-cvs1:/tmp/cvs-serv28568
Modified Files:
pep-0307.txt
Log Message:
Clarify __reduce__ and classic classes more.
Index: pep-0307.txt
===================================================================
RCS file: /cvsroot/python/python/nondist/peps/pep-0307.txt,v
retrieving revision 1.21
retrieving revision 1.22
diff -C2 -d -r1.21 -r1.22
*** pep-0307.txt 10 Feb 2003 21:25:25 -0000 1.21
--- pep-0307.txt 10 Feb 2003 21:34:28 -0000 1.22
***************
*** 146,151 ****
method, pickling its instances ignores the method, so that a classic
class cannot provide __reduce__ functionality in the sense intended
! here. A classic class must use __getinitargs__ and/or __gestate__
! to customize pickling. These are described below.
__reduce__ must return either a string or a tuple. If it returns
--- 146,152 ----
method, pickling its instances ignores the method, so that a classic
class cannot provide __reduce__ functionality in the sense intended
! here. (The copy_reg dispatch table is not consulted for classic
! classes either.) A classic class must use __getinitargs__ and/or
! __gestate__ to customize pickling. These are described below.
__reduce__ must return either a string or a tuple. If it returns