From: Jérémie Astor Date: Thu, 10 Sep 2020 19:40:41 +0000 (+0200) Subject: :art: is not a object anymore X-Git-Tag: nightly~1355 X-Git-Url: http://10.10.0.4:5575/?a=commitdiff_plain;h=c592b1c2256fbf71193113591c8e1d9750780e06;p=gwion.git :art: is not a object anymore --- diff --git a/src/lib/object_op.c b/src/lib/object_op.c index e12894ca..cfa04a18 100644 --- a/src/lib/object_op.c +++ b/src/lib/object_op.c @@ -438,14 +438,18 @@ ANN void struct_release(const VM_Shred shred, const Type base, const m_bit *ptr) } GWION_IMPORT(object_op) { - const Type t_null = gwi_mk_type(gwi, "@null", SZ_INT, "Object"); + const Type t_null = gwi_mk_type(gwi, "@null", SZ_INT, NULL); gwi->gwion->type[et_null] = t_null; GWI_BB(gwi_set_global_type(gwi, t_null, et_null)) GWI_BB(gwi_oper_cond(gwi, "Object", BranchEqInt, BranchNeqInt)) GWI_BB(gwi_oper_ini(gwi, "Object", "Object", NULL)) GWI_BB(gwi_oper_add(gwi, at_object)) GWI_BB(gwi_oper_emi(gwi, opem_at_object)) - GWI_BB(gwi_oper_end(gwi, "@=>", ObjectAssign)) + GWI_BB(gwi_oper_end(gwi, "@=>", NULL)) + GWI_BB(gwi_oper_ini(gwi, "@null", "Object", NULL)) + GWI_BB(gwi_oper_add(gwi, at_object)) + GWI_BB(gwi_oper_emi(gwi, opem_at_object)) + GWI_BB(gwi_oper_end(gwi, "@=>", NULL)) GWI_BB(gwi_oper_ini(gwi, "Object", "Object", "int")) GWI_BB(gwi_oper_end(gwi, "==", EqObject)) GWI_BB(gwi_oper_end(gwi, "!=", NeqObject)) @@ -455,9 +459,13 @@ GWION_IMPORT(object_op) { GWI_BB(gwi_oper_add(gwi, opck_implicit_null2obj)) GWI_BB(gwi_oper_emi(gwi, opem_implicit_null2obj)) GWI_BB(gwi_oper_end(gwi, "@implicit", NULL)) - GWI_BB(gwi_oper_ini(gwi, "@null", "Object", "int")) + GWI_BB(gwi_oper_ini(gwi, "@null", "Object", NULL)) GWI_BB(gwi_oper_add(gwi, opck_implicit_null2obj)) GWI_BB(gwi_oper_end(gwi, "@implicit", NULL)) + GWI_BB(gwi_oper_ini(gwi, "@null", "Object", NULL)) + GWI_BB(gwi_oper_add(gwi, opck_object_cast)) + GWI_BB(gwi_oper_emi(gwi, opem_object_cast)) + GWI_BB(gwi_oper_end(gwi, "$", NULL)) GWI_BB(gwi_oper_ini(gwi, NULL, "Object", "bool")) GWI_BB(gwi_oper_add(gwi, opck_unary_meta2)) GWI_BB(gwi_oper_end(gwi, "!", IntNot))