Browse Source

Threading

pull/46/head
Jure Šorn 5 years ago
parent
commit
182c0862a7
2 changed files with 2 additions and 2 deletions
  1. 2
      README.md
  2. 2
      index.html

2
README.md

@ -2015,7 +2015,7 @@ thread.start()
thread.join() # Waits for thread to finish.
```
* **Use `'kwargs=<dict>'` to pass keyword arguments to the function.**
* **Use `'daemon=True'` or the program will not be able to exit while the thread is alive.**
* **Use `'daemon=True'`, or the program will not be able to exit while the thread is alive.**
### Lock
```python

2
index.html

@ -1777,7 +1777,7 @@ thread.join() <span class="hljs-comment"># Waits for thre
<ul>
<li><strong>Use <code class="python hljs"><span class="hljs-string">'kwargs=&lt;dict&gt;'</span></code> to pass keyword arguments to the function.</strong></li>
<li><strong>Use <code class="python hljs"><span class="hljs-string">'daemon=True'</span></code> or the program will not be able to exit while the thread is alive.</strong></li>
<li><strong>Use <code class="python hljs"><span class="hljs-string">'daemon=True'</span></code>, or the program will not be able to exit while the thread is alive.</strong></li>
</ul>
<div><h3 id="lock">Lock</h3><pre><code class="python language-python hljs">lock = RLock()
lock.acquire() <span class="hljs-comment"># Waits for lock to be available.</span>

Loading…
Cancel
Save