Factory function that returns a new reentrant lock. A reentrant lock must be released by the thread that acquired it. Once a thread has acquired a reentrant lock, the same thread may acquire it again without blocking; the thread must release it once for each time it has acquire
(*args, **kwargs)
| 88 | Lock = _allocate_lock |
| 89 | |
| 90 | def RLock(*args, **kwargs): |
| 91 | """Factory function that returns a new reentrant lock. |
| 92 | |
| 93 | A reentrant lock must be released by the thread that acquired it. Once a |
| 94 | thread has acquired a reentrant lock, the same thread may acquire it again |
| 95 | without blocking; the thread must release it once for each time it has |
| 96 | acquired it. |
| 97 | |
| 98 | """ |
| 99 | if _CRLock is None: |
| 100 | return _PyRLock(*args, **kwargs) |
| 101 | return _CRLock(*args, **kwargs) |
| 102 | |
| 103 | class _RLock: |
| 104 | """This class implements reentrant lock objects. |
no outgoing calls
no test coverage detected