| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
Sorry, something went wrong.
PyDict_Contains() and PyDict_ContainsString() now fail with SystemError if the first argument is not a dict, frozendict, dict subclass or frozendict subclass.
| if (!PyAnyDict_Check(op)) { | ||
| PyErr_BadInternalCall(); | ||
| return -1; | ||
| } |
There was a problem hiding this comment.
Would you mind adding a versionchanged for this in the docs? This looks good otherwise.
Sorry, something went wrong.
There was a problem hiding this comment.
We do not document SystemError errors in the documentation. It's not really part of the API, but provided to be kind with developers.
Sorry, something went wrong.
There was a problem hiding this comment.
I'm not sure that's necessarily a good thing. It's helpful for extension authors to know whether they need to validate their input.
Sorry, something went wrong.
There was a problem hiding this comment.
They always need to validate their input. You're not supposed to hit SystemError in regular code.
Sorry, something went wrong.
PyDict_Contains() and PyDict_ContainsString() now fail with SystemError if the first argument is not a dict, frozendict, dict subclass or frozendict subclass.
PyDict_Contains() and PyDict_ContainsString() now fail with SystemError if the first argument is not a dict, frozendict, dict subclass or frozendict subclass.
| Back | FazBrowse Home | New Git URL |
PyDict_Contains() and PyDict_ContainsString() now fail with SystemError if the first argument is not a dict, frozendict, dict subclass or frozendict subclass.