// File: /workspace/github_c_makefile_star2_O3/chgzm[P]minic/parser.c
// Function: create_stmt_node
static StmtNode* create_stmt_node(const Vector* vec, int* index) {
    StmtNode* stmt_node = calloc(1, sizeof(StmtNode));

    const Token* token = vec->elements[*index];
    switch (token->type) {
    case TK_CASE:
    case TK_DEFAULT: {
        stmt_node->labeled_stmt_node = create_labeled_stmt_node(vec, index);
        if (stmt_node->labeled_stmt_node == NULL) {
            error("Failed to create labeled-statement node.\n");
            return NULL;
        }

        break;
    }
    case TK_WHILE: 
    case TK_FOR: {
        stmt_node->itr_stmt_node = create_itr_stmt_node(vec, index);
        if (stmt_node->itr_stmt_node == NULL) {
            error("Failed to create iteration-statement node.\n");
            return NULL;
        }

        break;
    } 
    case TK_RETURN: 
    case TK_BREAK:
    case TK_CONTINUE: {
        stmt_node->jump_stmt_node = create_jump_stmt_node(vec, index);
        if (stmt_node->jump_stmt_node == NULL) {
            error("Failed to create jump-statement node.\n");
            return NULL;
        }

        break;
    }
    case TK_IF: 
    case TK_SWITCH: {
        stmt_node->selection_stmt_node = create_selection_stmt_node(vec, index);
        if (stmt_node->selection_stmt_node == NULL) {
            error("Failed to create selection-statement node.\n");
            return NULL;
        }

        break;
    }
    case TK_LBRCKT: {
        stmt_node->compound_stmt_node = create_compound_stmt_node(vec, index);
        if (stmt_node->compound_stmt_node == NULL) {
            error("Failed to create compound-statement node.\n");
            return NULL;
        }

        break;
    }
    default: {
        stmt_node->expr_stmt_node = create_expr_stmt_node(vec, index);
        if (stmt_node->expr_stmt_node == NULL) {
            error("Failed to create expression-statement node.\n");
            return NULL;
        }

        break;
    }
    }

    return stmt_node;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rsi, %r14
movq %rdi, %r15
movl $0x1, %edi
movl $0x30, %esi
callq 0x10c0
movq %rax, %rbx
movq %r15, %r13
movq (%r15), %r15
movslq (%r14), %r12
movq (%r15,%r12,8), %rax
movl (%rax), %ebp
leal -0xd(%rbp), %eax
cmpl $0x16, %eax
ja 0x70a3
leaq 0x2c79(%rip), %rcx      # 0x9a44
movslq (%rcx,%rax,4), %rax
addq %rcx, %rax
jmpq *%rax
movl $0x1, %edi
movl $0x18, %esi
callq 0x10c0
movq %rax, %rdx
cmpl $0x14, %ebp
je 0x701d
cmpl $0x16, %ebp
jne 0x704f
movl $0x2, (%rdx)
movq %r12, %rbp
incq %rbp
movl %ebp, (%r14)
movq 0x8(%r15,%r12,8), %rax
cmpl $0x1f, (%rax)
je 0x6e45
movq %r13, %rdi
movq %r14, %rsi
movq %rdx, %r15
callq 0x5f8a
movq %rax, 0x10(%r15)
testq %rax, %rax
je 0x731e
movq (%r13), %rax
movslq (%r14), %rbp
movq (%rax,%rbp,8), %rax
movl (%rax), %edi
cmpl $0x1f, %edi
jne 0x746f
movq %r15, %rdx
incl %ebp
jmp 0x7043
movl $0x1, %edi
movl $0x30, %esi
callq 0x10c0
movq %rax, %r12
xorl %eax, %eax
callq 0x8738
movq %rax, %r15
movq %rax, 0x28(%r12)
movq %r13, %rbp
movq (%r13), %rdi
movslq (%r14), %rcx
movq (%rdi,%rcx,8), %rax
movl (%rax), %eax
cmpl $0xf, %eax
je 0x713f
cmpl $0x10, %eax
jne 0x7466
movq %rbx, %r15
leaq 0x1(%rcx), %rbx
movl %ebx, (%r14)
movq 0x8(%rdi,%rcx,8), %rax
movl (%rax), %edi
cmpl $0x21, %edi
jne 0x728c
leal 0x2(%rcx), %eax
movl %eax, (%r14)
movq %rbp, %rdi
movq %r14, %rsi
callq 0x5f8a
movq %rax, 0x10(%r12)
testq %rax, %rax
je 0x74a6
movq (%rbp), %rcx
movslq (%r14), %rax
movq (%rcx,%rax,8), %rcx
movl (%rcx), %edi
cmpl $0x22, %edi
movq %r15, %rbx
jne 0x72ab
incl %eax
movl %eax, (%r14)
jmp 0x7451
movl $0x1, %edi
movl $0x20, %esi
callq 0x10c0
cmpl $0x11, %ebp
je 0x7185
cmpl $0xd, %ebp
jne 0x721b
movq %rbx, %rbp
leal 0x1(%r12), %ebx
movl %ebx, (%r14)
movq 0x8(%r15,%r12,8), %rcx
movl (%rcx), %edi
cmpl $0x21, %edi
jne 0x7208
leal 0x2(%r12), %ecx
movl %ecx, (%r14)
movq %r13, %rdi
movq %r14, %rsi
movq %rax, %r15
callq 0x5f8a
movq %rax, 0x8(%r15)
testq %rax, %rax
je 0x74b9
movq (%r13), %rax
movslq (%r14), %rbx
movq (%rax,%rbx,8), %rax
movl (%rax), %edi
cmpl $0x22, %edi
jne 0x72fa
leal 0x1(%rbx), %eax
movl %eax, (%r14)
movq %r13, %rdi
movq %r14, %rsi
callq 0x6d86
movq %rax, 0x10(%r15)
testq %rax, %rax
je 0x74cb
movq %r15, %rdx
movq (%r13), %rcx
movslq (%r14), %rax
movq (%rcx,%rax,8), %rcx
cmpl $0xe, (%rcx)
jne 0x71fc
incl %eax
movl %eax, (%r14)
movl $0x1, (%rdx)
movq %r13, %rdi
movq %r14, %rsi
callq 0x6d86
movq %r15, %rdx
movq %rax, 0x18(%r15)
jmp 0x71f3
movq %rbx, (%rsp)
movl $0x1, %edi
movl $0x18, %esi
callq 0x10c0
leal 0x1(%r12), %ebx
movl %ebx, (%r14)
cmpl $0x12, %ebp
jne 0x70fa
movq %r13, %rdi
movq %r14, %rsi
movq %rax, %r15
callq 0x5e3d
movq %rax, 0x8(%r15)
testq %rax, %rax
je 0x7283
movq (%r13), %rax
movslq (%r14), %rbx
movq (%rax,%rbx,8), %rax
movl (%rax), %edi
cmpl $0x20, %edi
jne 0x72c6
leal 0x1(%rbx), %eax
movl %eax, (%r14)
movq %r13, %rdi
movq %r14, %rsi
jmp 0x7121
movq %rbx, %rcx
movl $0x1, (%rdx)
movq %r12, %rbx
incq %rbx
movl %ebx, (%r14)
movq 0x8(%r15,%r12,8), %rax
movl (%rax), %edi
cmpl $0x1f, %edi
jne 0x707f
leal 0x2(%r12), %ebp
movq %rcx, %rbx
movl %ebp, (%r14)
movq %rdx, 0x28(%rbx)
jmp 0x7541
movq %rbx, %rcx
leaq 0x1(%r12), %rbx
movl %ebx, (%r14)
movq 0x8(%r15,%r12,8), %rax
movl (%rax), %edi
cmpl $0x1f, %edi
jne 0x707f
addl $0x2, %r12d
movl %r12d, (%r14)
movq %rcx, %rbx
movq %rdx, 0x28(%rcx)
testq %rdx, %rdx
jne 0x7541
jmp 0x7097
callq 0x8681
leaq 0x2d65(%rip), %rdi      # 0x9df0
movl %ebx, %esi
movq %rax, %rdx
xorl %eax, %eax
callq 0x86ac
leaq 0x34a3(%rip), %rdi      # 0xa541
jmp 0x7538
movl $0x1, %edi
movl $0x8, %esi
callq 0x10c0
movq %rax, %r15
cmpl $0x1f, %ebp
jne 0x7231
incl %r12d
movl %r12d, (%r14)
movq %r15, 0x8(%rbx)
testq %r15, %r15
jne 0x7541
jmp 0x749a
movq %r13, %rdi
movq %r14, %rsi
callq 0x5890
movq %rax, 0x10(%rbx)
testq %rax, %rax
jne 0x7541
leaq 0x349f(%rip), %rdi      # 0xa594
jmp 0x7538
movl $0x1, (%rax)
movq 0x8(%r15,%r12,8), %rcx
movl (%rcx), %edi
cmpl $0x20, %edi
jne 0x7273
leal 0x2(%r12), %ecx
movl %ecx, (%r14)
movq %r13, %rdi
movq %r14, %rsi
movq %rax, %r15
callq 0x6d86
movq %rax, 0x10(%r15)
testq %rax, %rax
je 0x72e0
movq (%rsp), %rbx
movq %r15, (%rbx)
jmp 0x7541
movl $0x1, (%r12)
leal 0x1(%rcx), %eax
movl %eax, (%r14)
movq 0x8(%rdi,%rcx,8), %rax
movl (%rax), %eax
cmpl $0x21, %eax
jne 0x72a9
movq %rbx, %r13
movq %rcx, %rsi
addq $0x2, %rsi
movl %esi, (%r14)
movq 0x10(%rdi,%rcx,8), %rax
movl (%rax), %ebx
cmpl $0x1f, %ebx
jne 0x7344
leal 0x3(%rcx), %eax
movl %eax, (%r14)
jmp 0x73c8
movq %rbx, %rbp
movl $0x2, (%rax)
leal 0x1(%r12), %ebx
movl %ebx, (%r14)
movq 0x8(%r15,%r12,8), %rcx
movl (%rcx), %edi
cmpl $0x21, %edi
jne 0x7208
leal 0x2(%r12), %ecx
movl %ecx, (%r14)
movq %r13, %rdi
movq %r14, %rsi
movq %rax, %r15
callq 0x5f8a
movq %rax, 0x8(%r15)
testq %rax, %rax
je 0x74c2
movq (%r13), %rax
movslq (%r14), %rbx
movq (%rax,%rbx,8), %rax
movl (%rax), %edi
cmpl $0x22, %edi
jne 0x72fa
leal 0x1(%rbx), %eax
movl %eax, (%r14)
movq %r13, %rdi
movq %r14, %rsi
callq 0x6d86
movq %r15, %rdx
movq %rax, 0x10(%r15)
testq %rax, %rax
je 0x74cb
movq %rbp, %rbx
movq %rdx, 0x18(%rbp)
jmp 0x7541
callq 0x8681
leaq 0x2bdc(%rip), %rdi      # 0x9df0
movl %ebx, %esi
jmp 0x7308
movl %ebp, %edi
callq 0x8681
leaq 0x2bc7(%rip), %rdi      # 0x9df0
movl %r12d, %esi
jmp 0x7308
movq %r13, %rdi
movq %r14, %rsi
callq 0x5f8a
movq %rax, (%r15)
testq %rax, %rax
je 0x7331
movq %rbx, %rcx
movq (%r13), %rax
movslq (%r14), %rbx
movq (%rax,%rbx,8), %rax
movl (%rax), %edi
cmpl $0x1f, %edi
jne 0x7482
leal 0x1(%rbx), %eax
movl %eax, (%r14)
movq %rcx, %rbx
movq %r15, 0x8(%rcx)
jmp 0x7541
callq 0x8681
leaq 0x2b71(%rip), %rdi      # 0x9df0
movl %ebx, %esi
jmp 0x72d4
leaq 0x2e47(%rip), %rdi      # 0xa0d1
jmp 0x72e7
callq 0x8681
leaq 0x2b58(%rip), %rdi      # 0x9df0
movl %ebx, %esi
movq %rax, %rdx
xorl %eax, %eax
callq 0x86ac
jmp 0x74b4
movl %eax, %edi
callq 0x8681
leaq 0x3362(%rip), %rdi      # 0xa619
movq %rax, %rsi
xorl %eax, %eax
callq 0x86ac
jmp 0x7529
callq 0x8681
leaq 0x2b1e(%rip), %rdi      # 0x9df0
movl %ebx, %esi
movq %rax, %rdx
xorl %eax, %eax
callq 0x86ac
jmp 0x72ee
leaq 0x3305(%rip), %rdi      # 0xa5ec
xorl %eax, %eax
callq 0x86ac
leaq 0x31f6(%rip), %rdi      # 0xa4eb
jmp 0x7538
callq 0x8681
leaq 0x2aea(%rip), %rdi      # 0x9df0
movl %ebx, %esi
movq %rax, %rdx
xorl %eax, %eax
callq 0x86ac
leaq 0x324f(%rip), %rdi      # 0xa568
jmp 0x7538
leaq 0x2d89(%rip), %rdi      # 0xa0ae
xorl %eax, %eax
callq 0x86ac
jmp 0x7097
leaq 0x30a4(%rip), %rdi      # 0xa3dc
xorl %eax, %eax
callq 0x86ac
jmp 0x749a
callq 0x59c5
andl $-0x9, %ebx
cmpl $0x4, %ebx
je 0x73aa
testb %al, %al
jne 0x73aa
movq %rbp, %rdi
movq %r14, %rsi
callq 0x5f8a
movq %rax, 0x10(%r12)
testq %rax, %rax
je 0x74f7
movq (%rbp), %rcx
movslq (%r14), %rax
movq (%rcx,%rax,8), %rcx
movl (%rcx), %edi
cmpl $0x1f, %edi
jne 0x7500
incl %eax
jmp 0x717d
movq %rbp, %rdi
movq %r14, %rsi
callq 0x5335
testq %rax, %rax
je 0x7518
movq %r15, %rdi
movq %rax, %rsi
callq 0x876b
movslq (%r14), %rsi
movq (%rbp), %rdi
movq (%rdi,%rsi,8), %rax
movl (%rax), %ebx
callq 0x59c5
testb %al, %al
jne 0x738b
andl $-0x9, %ebx
cmpl $0x4, %ebx
je 0x738b
movq (%rbp), %rax
movslq (%r14), %rcx
movq (%rax,%rcx,8), %rdx
cmpl $0x1f, (%rdx)
movq %r13, %rbx
je 0x740a
movq %rbp, %rdi
movq %r14, %rsi
callq 0x5f8a
movq %rax, 0x18(%r12)
testq %rax, %rax
je 0x74e7
movq (%rbp), %rax
movslq (%r14), %rcx
movq (%rax,%rcx,8), %rdx
movl (%rdx), %edi
cmpl $0x1f, %edi
jne 0x72ab
leal 0x1(%rcx), %edx
movl %edx, (%r14)
movslq %ecx, %rcx
movq 0x8(%rax,%rcx,8), %rax
cmpl $0x22, (%rax)
je 0x744c
movq %rbp, %rdi
movq %r14, %rsi
callq 0x5f8a
movq %rax, 0x20(%r12)
testq %rax, %rax
je 0x74e7
movq (%rbp), %rax
movslq (%r14), %rdx
movq (%rax,%rdx,8), %rax
movl (%rax), %edi
cmpl $0x22, %edi
jne 0x72ab
incl %edx
movl %edx, (%r14)
movq %rbp, %rdi
movq %r14, %rsi
callq 0x6d86
movq %rax, 0x8(%r12)
testq %rax, %rax
je 0x74de
movq %r12, 0x20(%rbx)
jmp 0x7541
callq 0x8681
leaq 0x2975(%rip), %rdi      # 0x9df0
movl %ebp, %esi
jmp 0x708d
callq 0x8681
leaq 0x2962(%rip), %rdi      # 0x9df0
movl %ebx, %esi
movq %rax, %rdx
xorl %eax, %eax
callq 0x86ac
leaq 0x311e(%rip), %rdi      # 0xa5bf
jmp 0x7538
leaq 0x2f2f(%rip), %rdi      # 0xa3dc
xorl %eax, %eax
callq 0x86ac
movq %r15, %rbx
jmp 0x7529
leaq 0x30ff(%rip), %rdi      # 0xa5bf
jmp 0x74d2
leaq 0x2be5(%rip), %rdi      # 0xa0ae
jmp 0x74d2
leaq 0x2ff7(%rip), %rdi      # 0xa4c9
xorl %eax, %eax
callq 0x86ac
jmp 0x7312
leaq 0x314d(%rip), %rdi      # 0xa632
jmp 0x74ee
leaq 0x2eee(%rip), %rdi      # 0xa3dc
xorl %eax, %eax
callq 0x86ac
jmp 0x7529
leaq 0x2ede(%rip), %rdi      # 0xa3dc
jmp 0x751f
callq 0x8681
leaq 0x310d(%rip), %rdi      # 0xa619
movq %rax, %rsi
xorl %eax, %eax
callq 0x86ac
jmp 0x7526
leaq 0x3135(%rip), %rdi      # 0xa654
xorl %eax, %eax
callq 0x86ac
movq %r13, %rbx
movq $0x0, 0x20(%rbx)
leaq 0x2fdd(%rip), %rdi      # 0xa515
xorl %ebx, %ebx
xorl %eax, %eax
callq 0x86ac
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq