[Python-checkins] python/dist/src/Doc/lib libfuncs.tex,1.163,1.164
montanaro at users.sourceforge.net
montanaro at users.sourceforge.net
Sun Mar 21 11:05:34 EST 2004
Update of /cvsroot/python/python/dist/src/Doc/lib
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv25156
Modified Files:
libfuncs.tex
Log Message:
concrete example of why retaining old objects is good
Index: libfuncs.tex
===================================================================
RCS file: /cvsroot/python/python/dist/src/Doc/lib/libfuncs.tex,v
retrieving revision 1.163
retrieving revision 1.164
diff -C2 -d -r1.163 -r1.164
*** libfuncs.tex 20 Mar 2004 18:25:31 -0000 1.163
--- libfuncs.tex 21 Mar 2004 16:05:30 -0000 1.164
***************
*** 831,835 ****
to the module's advantage if it maintains a global table or cache of
objects --- with a \keyword{try} statement it can test for the
! table's presence and skip its initialization if desired.
It is legal though generally not very useful to reload built-in or
--- 831,843 ----
to the module's advantage if it maintains a global table or cache of
objects --- with a \keyword{try} statement it can test for the
! table's presence and skip its initialization if desired:
!
! \begin{verbatim}
! try:
! cache
! except NameError:
! cache = {}
! \end{verbatim}
!
It is legal though generally not very useful to reload built-in or
More information about the Python-checkins
mailing list