예제 #1
0
void dump_expr_assign_compound(const expr *e, dump *ctx)
{
	dump_desc_expr_newline(ctx, "compound assignment", e, 0);

	dump_printf_indent(ctx, 0, " %s%s=",
			e->assign_is_post ? "post-assignment " : "",
			op_to_str(e->bits.compoundop.op));

	if(e->bits.compoundop.upcast_ty){
		dump_printf_indent(ctx, 0, " upcast='%s'",
				type_to_str(e->bits.compoundop.upcast_ty));
	}

	dump_printf_indent(ctx, 0, "\n");

	dump_inc(ctx);
	dump_expr(e->lhs, ctx);
	dump_expr(e->rhs, ctx);
	dump_dec(ctx);
}
예제 #2
0
void dump_desc_expr(dump *ctx, const char *desc, const expr *e)
{
	dump_desc_expr_newline(ctx, desc, e, 1);
}