py: Tidy up returning NULL which should be MP_OBJ_NOT_SUPPORTED.

This commit is contained in:
Damien George
2014-05-10 13:55:11 +01:00
parent 2bb179e124
commit d0a5bf34f7
10 changed files with 60 additions and 61 deletions

View File

@@ -97,7 +97,7 @@ STATIC mp_obj_t float_unary_op(int op, mp_obj_t o_in) {
case MP_UNARY_OP_BOOL: return MP_BOOL(o->value != 0);
case MP_UNARY_OP_POSITIVE: return o_in;
case MP_UNARY_OP_NEGATIVE: return mp_obj_new_float(-o->value);
default: return NULL; // op not supported
default: return MP_OBJ_NOT_SUPPORTED;
}
}