// File: /workspace/github_cpp_makefile_star2_O3/zhengwangsun[P]pas2c/semantics.cpp
// Function: expression_list1(int, int)
int expression_list1(int k,int useFlag)
{
	TreeNode tNode= tree.node[k];
	TreeNode childNode;
	
    int flag1, flag2;
    if(lookahead(k) == 105)//105是,
    {
    	code[currentLine].append(",");
        flag1 = expression(tree.node[k].child[1],useFlag);
        if (useFlag == 3)//说明是函数调用，将读到的表达式类型记录在procArgument里面
        {
            procArgument.push_back(flag1);
        }
        
        flag2 = expression_list1(tree.node[k].child[2],useFlag);
        
        if (flag1 != -1 && flag2 != -1)//都不是-1
            return flag1;//将flag1的值返回，剩下的可以再递归看
        else
        {
            cout<<"type not match where expression_list'"<<endl;
            return -1;
        }
    }
    else if(lookahead(k) == 106)//106是e
    {
        return 0;
    }
    else
    {
        cout<<"expr_list' error!"<<endl;
        return -1;
    }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x158, %rsp            # imm = 0x158
movl %esi, %ebx
movslq %edi, %rax
imulq $0xa8, %rax, %rax
leaq 0xac6c0(%rip), %r13     # 0xb90c8
leaq (%rax,%r13), %r14
addq $0x8, %r14
leaq 0x8(%rsp), %rax
movl $0xb, %ecx
movq %rax, %rdi
movq %r14, %rsi
rep  movsq (%rsi), %es:(%rdi)
movb 0x58(%r14), %cl
movb %cl, 0x58(%rax)
leaq 0x68(%rsp), %rdi
leaq 0x78(%rsp), %rax
movq %rax, -0x10(%rax)
movq 0x60(%r14), %rsi
movq 0x68(%r14), %rdx
addq %rsi, %rdx
callq 0x7666
leaq 0x88(%rsp), %rdi
leaq 0x98(%rsp), %rax
movq %rax, -0x10(%rax)
movq 0x80(%r14), %rsi
movq 0x88(%r14), %rdx
addq %rsi, %rdx
callq 0x7666
movq 0xa0(%r14), %rax
movq %rax, 0xa8(%rsp)
leaq 0x120(%rsp), %rbp
movq %rbp, -0x10(%rbp)
xorl %r15d, %r15d
movq %r15, -0x8(%rbp)
movb %r15b, (%rbp)
leaq 0x140(%rsp), %r12
movq %r12, -0x10(%r12)
movq %r15, -0x8(%r12)
movb %r15b, (%r12)
movl $0x11, %edx
leaq 0x6fca(%rip), %rsi      # 0x13a84
cmpl $0x0, (%r14)
jle 0xcb78
movslq 0x4(%r14), %rax
imulq $0xa8, %rax, %rax
movl 0x5c(%r13,%rax), %eax
cmpl $0x6a, %eax
je 0xcbb8
cmpl $0x69, %eax
jne 0xcb78
movslq 0xa6ac3(%rip), %rax     # 0xb35b0
shlq $0x5, %rax
leaq 0xa5e38(%rip), %rdi     # 0xb2930
addq %rax, %rdi
leaq 0x6f9f(%rip), %rsi      # 0x13aa1
callq 0x23d0
movl 0x8(%r14), %edi
movl %ebx, %esi
callq 0xc02d
movl %eax, 0x4(%rsp)
cmpl $0x3, %ebx
jne 0xcb4b
movq 0xa5dd6(%rip), %rsi     # 0xb28f8
cmpq 0xa5dd7(%rip), %rsi     # 0xb2900
je 0xcb3a
movl %eax, (%rsi)
addq $0x4, %rsi
movq %rsi, 0xa5dc0(%rip)     # 0xb28f8
jmp 0xcb4b
leaq 0xa5daf(%rip), %rdi     # 0xb28f0
leaq 0x4(%rsp), %rdx
callq 0xf5d0
movl 0xc(%r14), %edi
movl %ebx, %esi
callq 0xc9e4
movl 0x4(%rsp), %r15d
cmpl $-0x1, %r15d
setne %cl
cmpl $-0x1, %eax
setne %al
testb %cl, %al
jne 0xcbb8
movl $0x25, %edx
leaq 0x6ee6(%rip), %rsi      # 0x13a5e
movq 0xc451(%rip), %rbx      # 0x18fd0
movq %rbx, %rdi
callq 0x2280
movq (%rbx), %rax
addq -0x18(%rax), %rbx
movq %rbx, %rdi
movl $0xa, %esi
callq 0x2200
movsbl %al, %esi
movq 0xc42b(%rip), %rdi      # 0x18fd0
callq 0x2030
movl $0xffffffff, %r15d      # imm = 0xFFFFFFFF
movq %rax, %rdi
callq 0x2150
movq 0x130(%rsp), %rdi
cmpq %r12, %rdi
je 0xcbd5
movq 0x140(%rsp), %rsi
incq %rsi
callq 0x2230
movq 0x110(%rsp), %rdi
cmpq %rbp, %rdi
je 0xcbf2
movq 0x120(%rsp), %rsi
incq %rsi
callq 0x2230
movq 0x88(%rsp), %rdi
leaq 0x98(%rsp), %rax
cmpq %rax, %rdi
je 0xcc17
movq 0x98(%rsp), %rsi
incq %rsi
callq 0x2230
movq 0x68(%rsp), %rdi
leaq 0x78(%rsp), %rax
cmpq %rax, %rdi
je 0xcc33
movq 0x78(%rsp), %rsi
incq %rsi
callq 0x2230
movl %r15d, %eax
addq $0x158, %rsp            # imm = 0x158
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
movq 0x68(%rsp), %rdi
leaq 0x78(%rsp), %rax
cmpq %rax, %rdi
je 0xcc83
movq 0x78(%rsp), %rsi
incq %rsi
callq 0x2230
jmp 0xcc83
movq %rax, %rbx
leaq 0xb0(%rsp), %rdi
callq 0xf396
leaq 0x8(%rsp), %rdi
callq 0xf396
movq %rbx, %rdi
callq 0x23a0