summaryrefslogtreecommitdiffstatshomepage
path: root/py/objobject.c
diff options
context:
space:
mode:
Diffstat (limited to 'py/objobject.c')
-rw-r--r--py/objobject.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/py/objobject.c b/py/objobject.c
index 00082dfe08..1652802805 100644
--- a/py/objobject.c
+++ b/py/objobject.c
@@ -36,8 +36,7 @@ typedef struct _mp_obj_object_t {
STATIC mp_obj_t object_make_new(const mp_obj_type_t *type, size_t n_args, size_t n_kw, const mp_obj_t *args) {
(void)args;
mp_arg_check_num(n_args, n_kw, 0, 0, false);
- mp_obj_object_t *o = m_new_obj(mp_obj_object_t);
- o->base.type = type;
+ mp_obj_object_t *o = mp_obj_malloc(mp_obj_object_t, type);
return MP_OBJ_FROM_PTR(o);
}