diff options
Diffstat (limited to 'py/builtin.c')
-rw-r--r-- | py/builtin.c | 10 |
1 files changed, 2 insertions, 8 deletions
diff --git a/py/builtin.c b/py/builtin.c index 8f93e843b5..a45b1463d9 100644 --- a/py/builtin.c +++ b/py/builtin.c @@ -64,7 +64,7 @@ MP_DEFINE_CONST_FUN_OBJ_VAR(mp_builtin___build_class___obj, 2, mp_builtin___buil static mp_obj_t mp_builtin___repl_print__(mp_obj_t o) { if (o != mp_const_none) { - mp_obj_print(o); + mp_obj_print(o, PRINT_REPR); printf("\n"); } return mp_const_none; @@ -285,13 +285,7 @@ static mp_obj_t mp_builtin_print(int n_args, const mp_obj_t *args) { if (i > 0) { printf(" "); } - if (MP_OBJ_IS_TYPE(args[i], &str_type)) { - // special case, print string raw - printf("%s", qstr_str(mp_obj_str_get(args[i]))); - } else { - // print the object Python style - mp_obj_print(args[i]); - } + mp_obj_print(args[i], PRINT_STR); } printf("\n"); return mp_const_none; |