Skip to content
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

gh-99537: Use Py_CLEAR() function in C code #99686

Merged
merged 1 commit into from
Nov 22, 2022
Merged

gh-99537: Use Py_CLEAR() function in C code #99686

merged 1 commit into from
Nov 22, 2022

Commits on Nov 22, 2022

  1. gh-99537: Use Py_CLEAR() function in C code

    Replace "Py_XDECREF(var); var = NULL;" with "Py_CLEAR(var);".
    
    Don't replace "Py_DECREF(var); var = NULL;" with "Py_CLEAR(var);". It
    would add an useless "if (var)" test in code path where var cannot be
    NULL.
    vstinner committed Nov 22, 2022
    Configuration menu
    Copy the full SHA
    93ff437 View commit details
    Browse the repository at this point in the history