A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://github.com/python/cpython/issues/108867 below:

Rename _PyThreadState_GetUnchecked() to public PyThreadState_GetUnchecked · Issue #108867 · python/cpython · GitHub

The _PyThreadState_UncheckedGet() function was added in Python 3.5 (2016) by issue #70342 with commit bfd316e. I was asked by PyPy developers to have an API to get the current thread state, but don't call Py_FatalError() if it's NULL. See: https://mail.python.org/pipermail/python-dev/2016-January/142767.html

In Python 3.13, I'm trying to remove private functions from the public C API: issue #106320.

Since _PyThreadState_UncheckedGet() had at least one user and exposing this API is revelant, I propose renaming the private _PyThreadState_UncheckedGet() function to PyThreadState_GetUnchecked() and so make it public, but not added it to the limited C API (not needed).

For the function name, see: capi-workgroup/problems#52 I propose to use the Unsafe suffix for "unsafe" function. Previously, the function used Unchecked, but it wasn't a suffix!

UPDATE: I renamed PyThreadState_GetUnsafe() to PyThreadState_GetUnchecked().

Linked PRs

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