-
-
Notifications
You must be signed in to change notification settings - Fork 33.7k
Closed
Labels
interpreter-core(Objects, Python, Grammar, and Parser dirs)(Objects, Python, Grammar, and Parser dirs)topic-C-APItype-featureA feature request or enhancementA feature request or enhancement
Description
Currently, self->mutex = (PyMutex){0}; or self->mutex = (PyMutex){_Py_UNLOCKED} pattern is used to initialize statically a PyMutex. It leaks implementation details of PyMutex.
I propose adding PyMutex_STATIC_INIT macro to abstract the initialization. The pattern becomes: self->mutex = PyMutex_STATIC_INIT;.
Linked PRs
Metadata
Metadata
Assignees
Labels
interpreter-core(Objects, Python, Grammar, and Parser dirs)(Objects, Python, Grammar, and Parser dirs)topic-C-APItype-featureA feature request or enhancementA feature request or enhancement