-Subproject commit b1fe9221196f766a5b3d11f6021340d747cab95c
+Subproject commit 269c530719fc73ae9427a01b379b184f2596911e
eArrayAccess,
eArrayGet,
eArrayAddr,
- eArrayValid,
eObjectInstantiate,
eRegAddRef,
eRegAddRefAddr,
#define ArrayAccess (f_instr)eArrayAccess
#define ArrayGet (f_instr)eArrayGet
#define ArrayAddr (f_instr)eArrayAddr
-#define ArrayValid (f_instr)eArrayValid
#define ObjectInstantiate (f_instr)eObjectInstantiate
#define RegAddRef (f_instr)eRegAddRef
#define RegAddRefAddr (f_instr)eRegAddRefAddr
ArrayAccess
ArrayGet
ArrayAddr
-ArrayValid
ObjectInstantiate
RegAddRef
RegAddRefAddr
if(freeable(a)) {
if(tflag(a, tflag_udef))
free_union_def(gwion->mp, a->info->udef);
- if(tflag(a, tflag_cdef))
+ else if(tflag(a, tflag_cdef))
class_def_cleaner(gwion, a->info->cdef);
}
+ if(a->effects.ptr)
+ vector_release(&a->effects);
if(a->nspc)
nspc_remref(a->nspc, gwion);
if(a->info->tuple)
const m_uint size, const m_bool is_var) {
const Instr get = emit_add_instr(emit, is_var ? ArrayAddr : ArrayGet);
get->m_val = depth * SZ_INT;
- emit_add_instr(emit, ArrayValid);
+// emit_add_instr(emit, ArrayValid);
const Instr push = emit_add_instr(emit, RegMove);
push->m_val = is_var ? SZ_INT : size;
}
ANN static inline m_bool array_do(const Emitter emit, const Array_Sub array, const m_bool is_var) {
- emit_gc(emit, -SZ_INT);
+// emit_gc(emit, -SZ_INT);
CHECK_BB(emit_exp(emit, array->exp));
array_loop(emit, array->depth);
array_finish(emit, array->depth, array->type->size, is_var);
env_err(env, v->from->loc, _("recursive type"));
env->context->error = false;
env_err(env, value->from->loc, _("recursive type"));
- env->context->error = true;
+ env->context->error = true;
+type_remref(t, env->gwion);
return GW_ERROR;
}
}
&®move, &®tomem, &®tomemother, &&overflow, &&funcusrend, &&funcmemberend,
&&sporkini, &&forkini, &&sporkfunc, &&sporkmemberfptr, &&sporkexp, &&sporkend,
&&brancheqint, &&branchneint, &&brancheqfloat, &&branchnefloat, &&unroll,
- &&arrayappend, &&autounrollinit, &&autoloop, &&arraytop, &&arrayaccess, &&arrayget, &&arrayaddr, &&arrayvalid,
+ &&arrayappend, &&autounrollinit, &&autoloop, &&arraytop, &&arrayaccess, &&arrayget, &&arrayaddr,
&&newobj, &&addref, &&addrefaddr, &&structaddref, &&structaddrefaddr, &&objassign, &&assign, &&remref,
&&except, &&allocmemberaddr, &&dotmember, &&dotfloat, &&dotother, &&dotaddr,
&&unioncheck, &&unionint, &&unionfloat, &&unionother, &&unionaddr,
*(m_bit**)(reg + (m_int)VAL2) = m_vector_addr(ARRAY(a.obj), *(m_int*)(reg + VAL));
PRAGMA_POP()
DISPATCH()
-arrayvalid:
-// are we sure it is the array ?
-// rather increase ref
- vector_pop(&shred->gc);
- DISPATCH()
newobj:
*(M_Object*)reg = new_object(vm->gwion->mp, NULL, (Type)VAL2);
reg += SZ_INT;