From 39dc1454788d1c6fb06c79871c7cd6e12aeb50a0 Mon Sep 17 00:00:00 2001 From: Damien George Date: Fri, 3 Oct 2014 19:52:22 +0100 Subject: py: Change [u]int to mp_[u]int_t in qstr.[ch], and some other places. This should pretty much resolve issue #50. --- py/objfun.c | 27 ++------------------------- 1 file changed, 2 insertions(+), 25 deletions(-) (limited to 'py/objfun.c') diff --git a/py/objfun.c b/py/objfun.c index 49c67c7f7a..e64d088bfa 100644 --- a/py/objfun.c +++ b/py/objfun.c @@ -116,29 +116,6 @@ const mp_obj_type_t mp_type_fun_builtin = { .binary_op = mp_obj_fun_binary_op, }; -#if 0 // currently unused, and semi-obsolete -mp_obj_t mp_make_function_var(int n_args_min, mp_fun_var_t fun) { - mp_obj_fun_builtin_t *o = m_new_obj(mp_obj_fun_builtin_t); - o->base.type = &mp_type_fun_native; - o->is_kw = false; - o->n_args_min = n_args_min; - o->n_args_max = MP_OBJ_FUN_ARGS_MAX; - o->fun = fun; - return o; -} - -// min and max are inclusive -mp_obj_t mp_make_function_var_between(int n_args_min, int n_args_max, mp_fun_var_t fun) { - mp_obj_fun_builtin_t *o = m_new_obj(mp_obj_fun_builtin_t); - o->base.type = &mp_type_fun_native; - o->is_kw = false; - o->n_args_min = n_args_min; - o->n_args_max = n_args_max; - o->fun = fun; - return o; -} -#endif - /******************************************************************************/ /* byte code functions */ @@ -161,9 +138,9 @@ STATIC void fun_bc_print(void (*print)(void *env, const char *fmt, ...), void *e #endif #if DEBUG_PRINT -STATIC void dump_args(const mp_obj_t *a, int sz) { +STATIC void dump_args(const mp_obj_t *a, mp_uint_t sz) { DEBUG_printf("%p: ", a); - for (int i = 0; i < sz; i++) { + for (mp_uint_t i = 0; i < sz; i++) { DEBUG_printf("%p ", a[i]); } DEBUG_printf("\n"); -- cgit v1.2.3