Add C API equivalent for `sys._is_gil_enabled()`
Dieses Issue hat noch niemand übernommen.
- Vorherrschende Sprache
- Python
- Sterne
- 77.2k
- Forks
- 35.9k
- PR-Merge-Kennzahlen
- PR-Kennzahlen ausstehend
Beschreibung
Feature or enhancement
Proposal:
sys._is_gil_enabled is documented as a CPython implementation detail - it would be good to have a C API to expose this in a stable way to C modules. Possibly, something like
int PyInterpreterState_IsGilEnabled(PyInterpreterState *interp)
We'd like to have a stable way to expose this information downstream, https://github.com/jpy-consortium/jpy/pull/218
Has this already been discussed elsewhere?
Links to previous discussion of this feature:
No response
Beitragsleitfaden
Erste Schritte
- Lies das ganze Issue und danach den Beitragsleitfaden des Projekts.
- Schreib ins Issue, dass du es übernimmst — das erspart doppelte Arbeit.
- Forke das Repository und arbeite in einem Branch.
- Öffne einen Pull Request, der die Issue-Nummer nennt.
Rechercherichtung
Beginne damit, die vorhandene Dokumentation zu sys._is_gil_enabled und die verknüpfte Diskussion über eine C API zum Abfragen des GIL-Zustands zu lesen. Prüfe den nachgelagerten jpy-Pull-Request und die bestehenden Konventionen für stabile C APIs, bevor du die vereinbarte API-Form festlegst; abgeschlossen ist die Aufgabe, wenn eine dokumentierte, stabile C API für C-Module verfügbar ist.
Vom Indexierungsmodell aus dem Issue-Text verfasst.
Bewertung
- Tech-Stack
- c, python
- Bereich
- api
- Issue-Typ
- Feature
- Schwierigkeit
- 5/5
- Geschätzter Aufwand
- Über eine Woche
- Aktivitätsstatus
- Veraltet
- Klarheit
- Größtenteils klar
- Anfängerfreundlichkeit
- 35/100