stage1 支持结构体初始化
This commit is contained in:
1 parent
72ae6d6994
commit
9bdb7f892e
4 files changed
+72
-15
No files matched your search
+2
-2
@@ -858,8 +858,8 @@ static void cg_node(cgen_t *cg, usize ref, const spl_ir_node_t *n) {
|
||||
spl_type_node_t *tn = spl_type_node(cg->ctx->type, n->arith.tid);
|
||||
if (tn && tn->kind == SPL_TYPE_BOOL) {
|
||||
cg_load_slot(cg, n->arith.left, SPL_BOOL);
|
||||
CG_PUSH(cg, SPL_U8, 0);
|
||||
CG_OP(cg, SPL_EQ, SPL_U8);
|
||||
CG_PUSH(cg, SPL_BOOL, 0);
|
||||
CG_OP(cg, SPL_EQ, SPL_BOOL);
|
||||
cg_store_slot(cg, ref, SPL_BOOL);
|
||||
} else {
|
||||
cg_unop(cg, ref, n, SPL_NOT);
|
||||
|
||||
Reference in new issue
Block a user