diff options
author | Damien George <damien.p.george@gmail.com> | 2014-06-28 10:27:23 +0100 |
---|---|---|
committer | Damien George <damien.p.george@gmail.com> | 2014-06-28 10:27:23 +0100 |
commit | e04a44e2f65d1ac49e5cce164d6010ff968f4d48 (patch) | |
tree | 3204ce1c708a6742d467e523ac95308ba61ecf8e /py/builtin.c | |
parent | b3a50f0f3e287d63fce274e29641a3bc57405d5d (diff) |
py: Small comments, name changes, use of machine_int_t.
Diffstat (limited to 'py/builtin.c')
-rw-r--r-- | py/builtin.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/py/builtin.c b/py/builtin.c index 1dd364911..9986b90d3 100644 --- a/py/builtin.c +++ b/py/builtin.c @@ -173,7 +173,7 @@ MP_DEFINE_CONST_FUN_OBJ_1(mp_builtin_callable_obj, mp_builtin_callable); STATIC mp_obj_t mp_builtin_chr(mp_obj_t o_in) { #if MICROPY_PY_BUILTINS_STR_UNICODE - int c = mp_obj_get_int(o_in); + machine_int_t c = mp_obj_get_int(o_in); char str[4]; int len = 0; if (c < 0x80) { @@ -198,7 +198,7 @@ STATIC mp_obj_t mp_builtin_chr(mp_obj_t o_in) { } return mp_obj_new_str(str, len, true); #else - int ord = mp_obj_get_int(o_in); + machine_int_t ord = mp_obj_get_int(o_in); if (0 <= ord && ord <= 0x10ffff) { char str[1] = {ord}; return mp_obj_new_str(str, 1, true); |