[Python-checkins] cpython (2.7): #14823: Simplify threading.Lock.acquire argument discussion.
r.david.murray
python-checkins at python.org
Thu May 17 15:15:18 CEST 2012
http://hg.python.org/cpython/rev/251463919f3c
changeset: 77011:251463919f3c
branch: 2.7
parent: 77003:ff52583a5576
user: R David Murray <rdmurray at bitdance.com>
date: Thu May 17 09:15:02 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
@@ -401,15 +401,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``.
.. method:: Lock.release()
--
Repository URL: http://hg.python.org/cpython
More information about the Python-checkins
mailing list