MCPcopy Create free account
hub / github.com/RT-Thread/env-windows / RLock

Function RLock

tools/python-3.11.9-amd64/Lib/threading.py:90–101  ·  view source on GitHub ↗

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)

Source from the content-addressed store, hash-verified

88Lock = _allocate_lock
89
90def 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
103class _RLock:
104 """This class implements reentrant lock objects.

Callers 14

__new__Method · 0.90
NonCallableMockClass · 0.90
ParserElementClass · 0.90
ParserElementClass · 0.90
ParserElementClass · 0.90
__init__Method · 0.90
__init__Method · 0.90
__init__Method · 0.90
__init__Method · 0.90
_lru_cache_wrapperFunction · 0.70
__init__Method · 0.70
__init__Method · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected