[Tim] >> It's probably better to add this to the (coded in Python) threading >> module, and include the Python implementation there. The threading >> module can replace the Python implementation with something from the >> (coded in C) thread module if possible. This is so implementations >> other than CPython get something usable right away (only CPython has >> the C API, of course). [Jim] > So the C implementation would be in the thread module, perhaps > under a funny name, but the official place to import it from is the > threading module? Exactly. An ancient example of this approach is at the bottom of string.py, which replaces some string.py Python functions with much faster ones from the (coded in C) strop module, if strop exists. A recent example is in CVS heapq.py, which replaces Python bits with C functions from _heapq (if available).
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4