-
-
Notifications
You must be signed in to change notification settings - Fork 31.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Light refactor: create a common _Py_closerange API #84602
Comments
Such an API can be used for both os.closerange and subprocess, re-using much of os_closerange_impl. Pull request enroute. |
Python/fileutils.c might be a better home for such helper function. You might move _Py_BEGIN_SUPPRESS_IPH / _Py_END_SUPPRESS_IPH macros into _Py_closerange(), even if currently it makes no diffence. (_Py_BEGIN_SUPPRESS_IPH is specific to Windows, os.closerange() uses it, and _posixsubprocess doesn't need it since it's not used on Windows.) See also the idea of reminding if the kernel supports the syscall or not: |
Would you like that on a distinct issue, or is it ok to reuse this BPO since it's a location improvement of an API just introduced? I've got a local branch now that:
|
Just reuse this bpo issue. I'll mark the PRs as "skip news"; don't worry about a new news blurb entry as it's all tied to the original one. |
Excellent, thank you. |
Thanks Kyle Evans! |
Note: these values reflect the state of the issue at the time it was migrated and might not reflect the current state.
Show more details
GitHub fields:
bugs.python.org fields:
The text was updated successfully, but these errors were encountered: