diff options
author | Victor Stinner <vstinner@python.org> | 2022-11-29 11:12:17 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-11-29 11:12:17 (GMT) |
commit | 4246fe977d850f8b78505c982f055d33d52ff339 (patch) | |
tree | fcc5f21f6a3963f175cad58f571bedc1016f6747 /Include/internal | |
parent | 4cfc1b8568bd8bf0d44fadc42ec86696d0561d33 (diff) | |
download | cpython-4246fe977d850f8b78505c982f055d33d52ff339.zip cpython-4246fe977d850f8b78505c982f055d33d52ff339.tar.gz cpython-4246fe977d850f8b78505c982f055d33d52ff339.tar.bz2 |
gh-99845: Change _PyDict_KeysSize() return type to size_t (#99848)
* Change _PyDict_KeysSize() and shared_keys_usable_size() return type
from signed (Py_ssize_t) to unsigned (size_t) type.
* new_values() argument type is now unsigned (size_t).
* init_inline_values() now uses size_t rather than int for the 'i'
iterator variable.
* type.__sizeof__() implementation now uses unsigned (size_t) type.
Diffstat (limited to 'Include/internal')
-rw-r--r-- | Include/internal/pycore_dict.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Include/internal/pycore_dict.h b/Include/internal/pycore_dict.h index 2b3b56b..c74a343 100644 --- a/Include/internal/pycore_dict.h +++ b/Include/internal/pycore_dict.h @@ -39,7 +39,7 @@ extern PyObject *_PyDict_FromKeys(PyObject *, PyObject *, PyObject *); * Returns the version number, or zero if it was not possible to get a version number. */ extern uint32_t _PyDictKeys_GetVersionForCurrentState(PyDictKeysObject *dictkeys); -extern Py_ssize_t _PyDict_KeysSize(PyDictKeysObject *keys); +extern size_t _PyDict_KeysSize(PyDictKeysObject *keys); /* _Py_dict_lookup() returns index of entry which can be used like DK_ENTRIES(dk)[index]. * -1 when no entry found, -3 when compare raises error. |