eObjectAssign,
eAssign,
eObjectRelease,
+ eSetObj,
eGWOP_EXCEPT,
eAllocMember4,
eDotMember,
#define ObjectAssign (f_instr)eObjectAssign
#define Assign (f_instr)eAssign
#define ObjectRelease (f_instr)eObjectRelease
+#define SetObj (f_instr)eSetObj
#define GWOP_EXCEPT (f_instr)eGWOP_EXCEPT
#define AllocMember4 (f_instr)eAllocMember4
#define DotMember (f_instr)eDotMember
ANN void emit_except(const Emitter emit, const Type t) {
if(!GET_FLAG(t, nonnull))
emit_add_instr(emit, GWOP_EXCEPT);
+ else
+ emit_add_instr(emit, SetObj);
}
ANN static inline m_bool tuple_index(const Emitter emit, struct ArrayAccessInfo *const info) {
&&brancheqint, &&branchneint, &&brancheqfloat, &&branchnefloat,
&&arrayappend, &&autoloop, &&autoloopptr, &&autoloopcount, &&arraytop, &&arrayaccess, &&arrayget, &&arrayaddr, &&arrayvalid,
&&newobj, &&addref, &&objassign, &&assign, &&remref,
- &&except, &&allocmemberaddr, &&dotmember, &&dotfloat, &&dotother, &&dotaddr,
+ &&setobj, &&except, &&allocmemberaddr, &&dotmember, &&dotfloat, &&dotother, &&dotaddr,
&&staticint, &&staticfloat, &&staticother,
&&dotfunc, &&dotstaticfunc, &&pushstaticcode,
&&gcini, &&gcadd, &&gcend,
remref:
release(*(M_Object*)(mem + VAL), shred);
DISPATCH()
+setobj:
+ a.obj = *(M_Object*)(reg-SZ_INT-VAL);
+ DISPATCH();
except:
/* TODO: Refactor except instruction *
* so that *