GeezerVisonThe World Wide Web, restored to 800 pixels of glory. | |||||||||||||||||
| Home|About|Gaming cabinet|Archives|How it works|Starter sites | |||||||||||||||||
GeezerVison is showing github.com — gh-112066: Use `PyDict_SetDefaultRef` in place of `PyDict_SetDefault`. by colesbury · Pull Request #112211 · python/cpython Conversation
|
| if (res < 0) { | ||
| Py_DECREF(key); | ||
| return NULL; | ||
| } | ||
| if (res == 1) { |
There was a problem hiding this comment.
The reason will be displayed to describe this comment to others. Learn more.
Maybe merge them in single test != 0?
Sorry, something went wrong.
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
The reason will be displayed to describe this comment to others. Learn more.
Thanks - I combined the cases.
Sorry, something went wrong.
There was an error while loading. Please reload this page.
…fault`. This changes a number of internal usages of `PyDict_SetDefault` to use `PyDict_SetDefaultRef`.
3899746 to
14a00f4
Compare
|
I've rebased this PR now that #112123 is merged. @serhiy-storchaka, would you please look over this? |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
There was an error while loading. Please reload this page.
Co-authored-by: Erlend E. Aasland <[email protected]>
|
Nice change, it makes the code more readable. |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
…fault`. (python#112211) This changes a number of internal usages of `PyDict_SetDefault` to use `PyDict_SetDefaultRef`. Co-authored-by: Erlend E. Aasland <[email protected]>
There was an error while loading. Please reload this page.
Successfully merging this pull request may close these issues.
There was an error while loading. Please reload this page.