objfloat: Missing default: caused incorrect results for unimplemented ops.

This commit is contained in:
Paul Sokolovsky 2014-03-31 01:38:25 +03:00
parent a96d3d0840
commit a8e60c1fde
1 changed files with 2 additions and 1 deletions

View File

@ -119,7 +119,8 @@ mp_obj_t mp_obj_float_binary_op(int op, mp_float_t lhs_val, mp_obj_t rhs_in) {
case MP_BINARY_OP_LESS_EQUAL: return MP_BOOL(lhs_val <= rhs_val);
case MP_BINARY_OP_MORE_EQUAL: return MP_BOOL(lhs_val >= rhs_val);
return NULL; // op not supported
default:
return NULL; // op not supported
}
return mp_obj_new_float(lhs_val);
}