]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
Clarify minor point about the ref() and proxy() constructors.
authorFred Drake <fdrake@acm.org>
Tue, 3 Feb 2004 20:50:45 +0000 (20:50 +0000)
committerFred Drake <fdrake@acm.org>
Tue, 3 Feb 2004 20:50:45 +0000 (20:50 +0000)
This matches what is already documented for corresponding feature of the C API.

Doc/lib/libweakref.tex

index 297d9b65e75b7c6c622248359cc026fdd4a657f2..6e022ae44f699c88a1003a86494cfaa52b77b620 100644 (file)
@@ -57,8 +57,9 @@ be made to support weak references; see section \ref{weakref-extension},
   Return a weak reference to \var{object}.  The original object can be
   retrieved by calling the reference object if the referent is still
   alive; if the referent is no longer alive, calling the reference
-  object will cause \code{None} to be returned.  If \var{callback} is
-  provided, it will be called when the object is about to be
+  object will cause \constant{None} to be returned.  If \var{callback} is
+  provided and not \constant{None},
+  it will be called when the object is about to be
   finalized; the weak reference object will be passed as the only
   parameter to the callback; the referent will no longer be available.
 
@@ -190,7 +191,7 @@ True
 \end{verbatim}
 
 If the referent no longer exists, calling the reference object returns
-\code{None}:
+\constant{None}:
 
 \begin{verbatim}
 >>> del o, o2