// File: /workspace/github_c_makefile_star2_O0/Mithreindeir[P]ewcc/src/frontend/parser.c
// Function: parse_postfix
struct expr *parse_postfix(struct parser *p)
{
	struct token *t;
	struct expr *e;
	if (!(e = parse_primary(p)))
		return NULL;
	while ((t = match(p, t_inc)) || (t = match(p, t_dec))
	       || (t = match(p, t_lbrack)) || (t = match(p, t_lparen))) {
		if (t->type == t_lbrack) {
			struct expr *sub;
			if (!(sub = parse_expr(p)))
				syntax_error(p,
					     "Invalid array subscript expression");
			if (!match(p, t_rbrack))
				syntax_error(p,
					     "Missing right bracket in subscript expression");
			e = binop_init(o_add, e, sub);
			e = unop_init(o_deref, e);
		} else if (t->type == t_lparen) {
			struct expr *call = call_init(e, NULL, 0);
			struct expr *arg;
			while ((arg=parse_asn_expr(p))) {
				call_addarg(CALL(call), arg);
				if (!match(p, t_comma)) break;
			}
			if (!match(p, t_rparen))
				syntax_error(p, "Missing right parentheses in function call");
			e = call;
		} else {
			e = unop_init(t->type ==
				      t_inc ? o_postinc : o_postdec, e);
		}
	}

	return e;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movq %rdi, -0x10(%rbp)
movq -0x10(%rbp), %rdi
callq 0x9790
movq %rax, -0x20(%rbp)
cmpq $0x0, %rax
jne 0x98cc
movq $0x0, -0x8(%rbp)
jmp 0x9a8b
jmp 0x98ce
movq -0x10(%rbp), %rdi
movl $0x22, %esi
callq 0xaab0
movq %rax, %rcx
movq %rcx, -0x18(%rbp)
movb $0x1, %al
cmpq $0x0, %rcx
movb %al, -0x39(%rbp)
jne 0x994a
movq -0x10(%rbp), %rdi
movl $0x23, %esi
callq 0xaab0
movq %rax, %rcx
movq %rcx, -0x18(%rbp)
movb $0x1, %al
cmpq $0x0, %rcx
movb %al, -0x39(%rbp)
jne 0x994a
movq -0x10(%rbp), %rdi
movl $0x16, %esi
callq 0xaab0
movq %rax, %rcx
movq %rcx, -0x18(%rbp)
movb $0x1, %al
cmpq $0x0, %rcx
movb %al, -0x39(%rbp)
jne 0x994a
movq -0x10(%rbp), %rdi
movl $0x14, %esi
callq 0xaab0
movq %rax, -0x18(%rbp)
cmpq $0x0, %rax
setne %al
movb %al, -0x39(%rbp)
movb -0x39(%rbp), %al
testb $0x1, %al
jne 0x9956
jmp 0x9a83
movq -0x18(%rbp), %rax
cmpl $0x16, 0x14(%rax)
jne 0x99d1
movq -0x10(%rbp), %rdi
callq 0x9860
movq %rax, -0x28(%rbp)
cmpq $0x0, %rax
jne 0x9983
movq -0x10(%rbp), %rdi
leaq 0x2f34(%rip), %rsi      # 0xc8b2
callq 0xabb0
movq -0x10(%rbp), %rdi
movl $0x17, %esi
callq 0xaab0
cmpq $0x0, %rax
jne 0x99a7
movq -0x10(%rbp), %rdi
leaq 0x2f33(%rip), %rsi      # 0xc8d5
callq 0xabb0
movq -0x20(%rbp), %rsi
movq -0x28(%rbp), %rdx
xorl %edi, %edi
callq 0x7d50
movq %rax, -0x20(%rbp)
movq -0x20(%rbp), %rsi
movl $0x13, %edi
callq 0x7db0
movq %rax, -0x20(%rbp)
jmp 0x9a7e
movq -0x18(%rbp), %rax
cmpl $0x14, 0x14(%rax)
jne 0x9a58
movq -0x20(%rbp), %rdi
xorl %eax, %eax
movl %eax, %esi
xorl %edx, %edx
callq 0x7b80
movq %rax, -0x30(%rbp)
movq -0x10(%rbp), %rdi
callq 0x9aa0
movq %rax, -0x38(%rbp)
cmpq $0x0, %rax
je 0x9a2a
movq -0x30(%rbp), %rax
movq 0x8(%rax), %rdi
movq -0x38(%rbp), %rsi
callq 0x7be0
movq -0x10(%rbp), %rdi
movl $0x29, %esi
callq 0xaab0
cmpq $0x0, %rax
jne 0x9a28
jmp 0x9a2a
jmp 0x99ee
movq -0x10(%rbp), %rdi
movl $0x15, %esi
callq 0xaab0
cmpq $0x0, %rax
jne 0x9a4e
movq -0x10(%rbp), %rdi
leaq 0x2eba(%rip), %rsi      # 0xc903
callq 0xabb0
movq -0x30(%rbp), %rax
movq %rax, -0x20(%rbp)
jmp 0x9a7c
movq -0x18(%rbp), %rax
movl 0x14(%rax), %ecx
movl $0x16, %edi
movl $0x14, %eax
cmpl $0x22, %ecx
cmovel %eax, %edi
movq -0x20(%rbp), %rsi
callq 0x7db0
movq %rax, -0x20(%rbp)
jmp 0x9a7e
jmp 0x98ce
movq -0x20(%rbp), %rax
movq %rax, -0x8(%rbp)
movq -0x8(%rbp), %rax
addq $0x40, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)