[Python-checkins] cpython (merge 3.2 -> default): #14823: Simplify threading.Lock.acquire argument discussion.
r.david.murray
python-checkins at python.org
Thu May 17 15:15:17 CEST 2012
http://hg.python.org/cpython/rev/b5e95bb79ba3
changeset: 77010:b5e95bb79ba3
parent: 77008:f6a207d86154
parent: 77009:6ab4128acccc
user: R David Murray <rdmurray at bitdance.com>
date: Thu May 17 09:14:28 2012 -0400
summary:
#14823: Simplify threading.Lock.acquire argument discussion.
files:
Doc/library/threading.rst | 13 +++++--------
1 files changed, 5 insertions(+), 8 deletions(-)
diff --git a/Doc/library/threading.rst b/Doc/library/threading.rst
--- a/Doc/library/threading.rst
+++ b/Doc/library/threading.rst
@@ -426,15 +426,12 @@
Acquire a lock, blocking or non-blocking.
- When invoked without arguments, block until the lock is unlocked, then set it to
- locked, and return true.
+ When invoked with the *blocking* argument set to ``True`` (the default),
+ block until the lock is unlocked, then set it to locked and return ``True``.
- When invoked with the *blocking* argument set to true, do the same thing as when
- called without arguments, and return true.
-
- When invoked with the *blocking* argument set to false, do not block. If a call
- without an argument would block, return false immediately; otherwise, do the
- same thing as when called without arguments, and return true.
+ When invoked with the *blocking* argument set to ``False``, do not block.
+ If a call with *blocking* set to ``True`` would block, return ``False``
+ immediately; otherwise, set the lock to locked and return ``True``.
When invoked with the floating-point *timeout* argument set to a positive
value, block for at most the number of seconds specified by *timeout*
--
Repository URL: http://hg.python.org/cpython
More information about the Python-checkins
mailing list