From c88cfe165b0ab39c5d9392fb02dd12f22be1a28d Mon Sep 17 00:00:00 2001 From: Damien George Date: Thu, 23 Mar 2017 16:17:40 +1100 Subject: py: Use size_t as len argument and return type of mp_get_index. These values are used to compute memory addresses and so size_t is the more appropriate type to use. --- py/objstrunicode.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'py/objstrunicode.c') diff --git a/py/objstrunicode.c b/py/objstrunicode.c index 441ec293d..9a6ce9b9a 100644 --- a/py/objstrunicode.c +++ b/py/objstrunicode.c @@ -120,7 +120,7 @@ const byte *str_index_to_ptr(const mp_obj_type_t *type, const byte *self_data, s // so it must handle bytes. if (type == &mp_type_bytes) { // Taken from objstr.c:str_index_to_ptr() - mp_uint_t index_val = mp_get_index(type, self_len, index, is_slice); + size_t index_val = mp_get_index(type, self_len, index, is_slice); return self_data + index_val; } -- cgit v1.2.3