// File: /workspace/github_c_makefile_star2_O1/MartinNovotny25[P]VUT-FIT-IFJ2020/parser.c
// Function: rule_for_assign
void rule_for_assign() {
    switch (token.type) {
        case t_IDENTIFIER:
            token = get_next_token(stdin);
            TDLLInsertLast(&tokens, token);

            rule_id_n();

            //môže príst iba token assign =
            if (token.type != t_ASSIGN) { error_call(ERR_SYN, &tokens); }
            else { token = get_next_token(stdin); TDLLInsertLast(&tokens, token); }

            TDLLInitList(&psa_list);

            if (token.type == t_BRACES_L) {error_call(ERR_SYN, &tokens);}

            while (token.type != t_BRACES_L && token.type != t_COMMA)
            {
                if ((token.type == t_PLUS)
                    || (token.type == t_MINUS)
                    || (token.type == t_DIVIDE)
                    || (token.type == t_MULTIPLY)
                    || (token.type == t_RIGHT_BRACKET)
                    || (token.type == t_LEFT_BRACKET)
                    || (token.type == t_LESS)
                    || (token.type == t_LESSOREQUAL)
                    || (token.type == t_GREATER)
                    || (token.type == t_GREATEROREQUAL)
                    || (token.type == t_EQUAL)
                    || (token.type == t_NOT_EQUAL)
                    || (token.type == t_IDENTIFIER)
                    || (token.type == t_FLOAT)
                    || (token.type == t_INT_NON_ZERO)
                    || (token.type == t_INT_ZERO)
                    || (token.type == t_STRING)) {

                    TDLLInsertLast(&psa_list, token);
                    token = get_next_token(stdin); TDLLInsertLast(&tokens, token);

                } else {error_call(ERR_SYN, &tokens);}


            }
            evaluation(&psa_list, &tokens);
            TDLLDisposeList(&psa_list);

            rule_exp_n();
            break;

         // otváracia množinová zátvorka -- začiatok bloku tela for
        case t_BRACES_L:
            break;
        // hocico ine - break
        default:
            error_call(ERR_SYN, &tokens);
    }
}

// Assembly:
movl 0x989b(%rip), %eax      # 0xc3d0
cmpl $0x34, %eax
je 0x2ba7
cmpl $0x13, %eax
jne 0x2ba8
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
movq 0x9489(%rip), %r15      # 0xbfd8
movq (%r15), %rdi
callq 0x31f0
movq %rax, 0x986a(%rip)      # 0xc3c8
movl %edx, 0x986c(%rip)      # 0xc3d0
leaq 0x9845(%rip), %rdi      # 0xc3b0
movq %rax, %rsi
callq 0x1726
callq 0x28ff
cmpl $0x3, 0x9851(%rip)      # 0xc3d0
jne 0x2bb9
movq (%r15), %rdi
callq 0x31f0
movq %rax, 0x9838(%rip)      # 0xc3c8
movl %edx, 0x983a(%rip)      # 0xc3d0
leaq 0x9813(%rip), %rdi      # 0xc3b0
movq %rax, %rsi
callq 0x1726
jmp 0x2bca
retq
leaq 0x9801(%rip), %rsi      # 0xc3b0
movl $0x2, %edi
jmp 0x42c8
leaq 0x97f0(%rip), %rsi      # 0xc3b0
movl $0x2, %edi
callq 0x42c8
leaq 0x9807(%rip), %rdi      # 0xc3d8
callq 0x16a7
cmpl $0x34, 0x97f3(%rip)     # 0xc3d0
jne 0x2bf0
leaq 0x97ca(%rip), %rsi      # 0xc3b0
movl $0x2, %edi
callq 0x42c8
leaq 0x97b9(%rip), %rbx      # 0xc3b0
movabsq $0xa03c00b0fc6, %r12    # imm = 0xA03C00B0FC6
leaq 0x97d0(%rip), %r14      # 0xc3d8
movabsq $0x10000000000020, %r13 # imm = 0x10000000000020
movl 0x97b8(%rip), %edx      # 0xc3d0
cmpq $0x34, %rdx
ja 0x2c5b
btq %rdx, %r12
jae 0x2c55
movq 0x979d(%rip), %rsi      # 0xc3c8
movq %r14, %rdi
callq 0x1726
movq (%r15), %rdi
callq 0x31f0
movq %rax, 0x9786(%rip)      # 0xc3c8
movl %edx, 0x9788(%rip)      # 0xc3d0
movq %rbx, %rdi
movq %rax, %rsi
callq 0x1726
jmp 0x2c12
btq %rdx, %r13
jb 0x2c6a
movl $0x2, %edi
movq %rbx, %rsi
callq 0x42c8
jmp 0x2c12
leaq 0x9767(%rip), %rbx      # 0xc3d8
leaq 0x9738(%rip), %rsi      # 0xc3b0
movq %rbx, %rdi
callq 0x7d13
movq %rbx, %rdi
callq 0x16b6
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
jmp 0x2e2e