summaryrefslogtreecommitdiff
path: root/py/objstr.c
diff options
context:
space:
mode:
authorPaul Sokolovsky <pfalcon@users.sourceforge.net>2014-06-28 23:14:30 +0300
committerPaul Sokolovsky <pfalcon@users.sourceforge.net>2014-06-28 23:15:29 +0300
commit9e215fa4c2773b7a4102aec4203c9bf74aa0eccc (patch)
tree45201e201128c5be451bb292699f72e5395d698d /py/objstr.c
parenta62da515af72c67cbe74efbd6a74cd0a1e7d935e (diff)
py: Make unichar_charlen() accept/return machine_uint_t.
Diffstat (limited to 'py/objstr.c')
-rw-r--r--py/objstr.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/py/objstr.c b/py/objstr.c
index a4749369d..b13517b63 100644
--- a/py/objstr.c
+++ b/py/objstr.c
@@ -1448,7 +1448,7 @@ STATIC mp_obj_t str_count(uint n_args, const mp_obj_t *args) {
// if needle_len is zero then we count each gap between characters as an occurrence
if (needle_len == 0) {
- return MP_OBJ_NEW_SMALL_INT((machine_uint_t)unichar_charlen((const char*)start, end - start) + 1);
+ return MP_OBJ_NEW_SMALL_INT(unichar_charlen((const char*)start, end - start) + 1);
}
// count the occurrences