File tree Expand file tree Collapse file tree 1 file changed +5
-5
lines changed
Expand file tree Collapse file tree 1 file changed +5
-5
lines changed Original file line number Diff line number Diff line change @@ -331,27 +331,27 @@ dictkeys_decref(PyDictKeysObject *dk)
331331
332332/* lookup indices. returns DKIX_EMPTY, DKIX_DUMMY, or ix >=0 */
333333static inline Py_ssize_t
334- dictkeys_get_index (PyDictKeysObject * keys , Py_ssize_t i )
334+ dictkeys_get_index (const PyDictKeysObject * keys , Py_ssize_t i )
335335{
336336 Py_ssize_t s = DK_SIZE (keys );
337337 Py_ssize_t ix ;
338338
339339 if (s <= 0xff ) {
340- int8_t * indices = (int8_t * )(keys -> dk_indices );
340+ const int8_t * indices = (const int8_t * )(keys -> dk_indices );
341341 ix = indices [i ];
342342 }
343343 else if (s <= 0xffff ) {
344- int16_t * indices = (int16_t * )(keys -> dk_indices );
344+ const int16_t * indices = (const int16_t * )(keys -> dk_indices );
345345 ix = indices [i ];
346346 }
347347#if SIZEOF_VOID_P > 4
348348 else if (s > 0xffffffff ) {
349- int64_t * indices = (int64_t * )(keys -> dk_indices );
349+ const int64_t * indices = (const int64_t * )(keys -> dk_indices );
350350 ix = indices [i ];
351351 }
352352#endif
353353 else {
354- int32_t * indices = (int32_t * )(keys -> dk_indices );
354+ const int32_t * indices = (const int32_t * )(keys -> dk_indices );
355355 ix = indices [i ];
356356 }
357357 assert (ix >= DKIX_DUMMY );
You can’t perform that action at this time.
0 commit comments