From 963a5a3e82ded7ee75adae72ae7cb14796fa150e Mon Sep 17 00:00:00 2001 From: Damien George Date: Fri, 16 Jan 2015 17:47:07 +0000 Subject: py, unix: Allow to compile with -Wsign-compare. See issue #699. --- py/bc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'py/bc.c') diff --git a/py/bc.c b/py/bc.c index 6aa20172f..9498b4f18 100644 --- a/py/bc.c +++ b/py/bc.c @@ -116,7 +116,7 @@ void mp_setup_code_state(mp_code_state *code_state, mp_obj_t self_in, mp_uint_t // Apply processing and check below only if we don't have kwargs, // otherwise, kw handling code below has own extensive checks. if (n_kw == 0 && !self->has_def_kw_args) { - if (n_args >= self->n_pos_args - self->n_def_args) { + if (n_args >= (mp_uint_t)(self->n_pos_args - self->n_def_args)) { // given enough arguments, but may need to use some default arguments for (mp_uint_t i = n_args; i < self->n_pos_args; i++) { code_state->state[n_state - 1 - i] = self->extra_args[i - (self->n_pos_args - self->n_def_args)]; -- cgit v1.2.3