// File: acliusBackHome[P]kamaya/dist/ParseDeclaration.cpp
// Function: ParseConstant::wider_const_type(ConstValueType, ConstValueType)
ConstValueType ParseConstant::wider_const_type(ConstValueType type1, ConstValueType type2) {
    switch (type1) {
        case C_BOOL:
        case C_STRING:
        case C_UNDEFINED:
            if (type1 == type2) {
                return type1;
            }
            break;
        case C_SIGNED: {
            switch (type2) {
                case C_SIGNED:
                    return C_SIGNED;
                case C_UNSIGNED:
                    return C_UNSIGNED;
                case C_FLOAT:
                    return C_FLOAT;
                case C_STRING:
                case C_BOOL:
                case C_UNDEFINED:
                    break;
            }
            break;
        }
        case C_UNSIGNED: {
            switch (type2) {
                case C_SIGNED:
                case C_UNSIGNED:
                    return C_UNSIGNED;
                case C_FLOAT:
                    return C_FLOAT;
                case C_STRING:
                case C_BOOL:
                case C_UNDEFINED:
                    break;
            }
            break;
        }
        case C_FLOAT: {
            switch (type2) {
                case C_SIGNED:
                case C_UNSIGNED:
                case C_FLOAT:
                    return C_FLOAT;
                case C_STRING:
                case C_BOOL:
                case C_UNDEFINED:
                    break;
            }
            break;
        }
    }
    printf("ParseConstant::wider_const_type(ConstValueType type1, ConstValueType type2):"
           "警告:常量类型%s 与 %s无法进行运算\n", get_const_type_name(type1).c_str(),
           get_const_type_name(type2).c_str());
    return C_UNDEFINED;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x90, %rsp
movl %edi, -0x8(%rbp)
movl %esi, -0xc(%rbp)
movl -0x8(%rbp), %eax
movq %rax, -0x68(%rbp)
subq $0x5, %rax
ja 0x6a14a
movq -0x68(%rbp), %rax
leaq 0x26737(%rip), %rcx     # 0x90794
movslq (%rcx,%rax,4), %rax
addq %rcx, %rax
jmpq *%rax
movl -0x8(%rbp), %eax
cmpl -0xc(%rbp), %eax
jne 0x6a079
movl -0x8(%rbp), %eax
movl %eax, -0x4(%rbp)
jmp 0x6a1e4
jmp 0x6a14a
movl -0xc(%rbp), %eax
movq %rax, -0x70(%rbp)
subq $0x5, %rax
ja 0x6a0c5
movq -0x70(%rbp), %rax
leaq 0x26716(%rip), %rcx     # 0x907ac
movslq (%rcx,%rax,4), %rax
addq %rcx, %rax
jmpq *%rax
movl $0x1, -0x4(%rbp)
jmp 0x6a1e4
movl $0x2, -0x4(%rbp)
jmp 0x6a1e4
movl $0x3, -0x4(%rbp)
jmp 0x6a1e4
jmp 0x6a0c5
jmp 0x6a14a
movl -0xc(%rbp), %eax
movl %eax, -0x74(%rbp)
testl %eax, %eax
je 0x6a111
jmp 0x6a0d6
movl -0x74(%rbp), %eax
decl %eax
subl $0x2, %eax
jb 0x6a0f9
jmp 0x6a0e2
movl -0x74(%rbp), %eax
subl $0x3, %eax
je 0x6a105
jmp 0x6a0ec
movl -0x74(%rbp), %eax
addl $-0x4, %eax
subl $0x2, %eax
jb 0x6a111
jmp 0x6a113
movl $0x2, -0x4(%rbp)
jmp 0x6a1e4
movl $0x3, -0x4(%rbp)
jmp 0x6a1e4
jmp 0x6a113
jmp 0x6a14a
movl -0xc(%rbp), %eax
movl %eax, -0x78(%rbp)
testl %eax, %eax
je 0x6a146
jmp 0x6a121
movl -0x78(%rbp), %eax
decl %eax
subl $0x3, %eax
jb 0x6a13a
jmp 0x6a12d
movl -0x78(%rbp), %eax
addl $-0x4, %eax
subl $0x2, %eax
jb 0x6a146
jmp 0x6a148
movl $0x3, -0x4(%rbp)
jmp 0x6a1e4
jmp 0x6a148
jmp 0x6a14a
movl -0x8(%rbp), %esi
leaq -0x30(%rbp), %rdi
movq %rdi, -0x88(%rbp)
callq 0x697c0
movq -0x88(%rbp), %rdi
callq 0x4180
movq %rax, -0x80(%rbp)
movl -0xc(%rbp), %esi
leaq -0x50(%rbp), %rdi
callq 0x697c0
jmp 0x6a17b
leaq -0x50(%rbp), %rdi
callq 0x4180
movq -0x80(%rbp), %rsi
movq %rax, %rdx
leaq 0x268c2(%rip), %rdi     # 0x90a54
xorl %eax, %eax
callq 0x4080
jmp 0x6a19b
leaq -0x50(%rbp), %rdi
callq 0x4688
leaq -0x30(%rbp), %rdi
callq 0x4688
movl $0x5, -0x4(%rbp)
jmp 0x6a1e4
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x58(%rbp)
movl %eax, -0x5c(%rbp)
jmp 0x6a1d9
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x58(%rbp)
movl %eax, -0x5c(%rbp)
leaq -0x50(%rbp), %rdi
callq 0x4688
leaq -0x30(%rbp), %rdi
callq 0x4688
jmp 0x6a1f0
movl -0x4(%rbp), %eax
addq $0x90, %rsp
popq %rbp
retq
movq -0x58(%rbp), %rdi
callq 0x45e0
nopl (%rax)