// File: /workspace/github_c_makefile_star2_O1/johsteffens[P]beth/lib/bcore/bcore_st.c
// Function: st_s_copy_typed
er_t st_s_copy_typed( st_s* o, tp_t type, vc_t src )
{
    switch( type )
    {
        case TYPEOF_st_s: st_s_copy( o,              (const st_s*)src ); break;
        case TYPEOF_sc_t: st_s_copy_sc( o,          *(const sc_t*)src ); break;
        case TYPEOF_sd_t: st_s_copy_sc( o,          *(const sc_t*)src ); break;
        case TYPEOF_s0_t: st_s_copyf( o, "%"PRIi8 , *(const s0_t*)src ); break;
        case TYPEOF_s1_t: st_s_copyf( o, "%"PRIi16, *(const s1_t*)src ); break;
        case TYPEOF_s2_t: st_s_copyf( o, "%"PRIi32, *(const s2_t*)src ); break;
        case TYPEOF_s3_t: st_s_copyf( o, "%"PRIi64, *(const s3_t*)src ); break;
        case TYPEOF_u0_t: st_s_copyf( o, "%"PRIu8 , *(const u0_t*)src ); break;
        case TYPEOF_u1_t: st_s_copyf( o, "%"PRIu16, *(const u1_t*)src ); break;
        case TYPEOF_u2_t: st_s_copyf( o, "%"PRIu32, *(const u2_t*)src ); break;
        case TYPEOF_u3_t: st_s_copyf( o, "%"PRIu64, *(const u3_t*)src ); break;
        case TYPEOF_f2_t: st_s_copyf( o, "%g",      *(const f2_t*)src ); break;
        case TYPEOF_f3_t: st_s_copyf( o, "%.18lg",  *(const f3_t*)src ); break;
        case TYPEOF_sz_t: st_s_copyf( o, "%ti",     *(const sz_t*)src ); break;
        case TYPEOF_uz_t: st_s_copyf( o, "%zu",     *(const uz_t*)src ); break;
        case TYPEOF_vd_t: st_s_copyf( o, "%p",      *(const vd_t*)src ); break;
        case TYPEOF_vc_t: st_s_copyf( o, "%p",      *(const vc_t*)src ); break;

        case TYPEOF_smax_t:   st_s_copyf( o, "%"PRIiMAX, *(const smax_t*)src ); break;
        case TYPEOF_umax_t:   st_s_copyf( o, "%"PRIuMAX, *(const umax_t*)src ); break;
        case TYPEOF_offset_t: st_s_copyf( o, "%zu",      *(const offset_t*)src ); break;

        case TYPEOF_er_t: st_s_copyf( o, "%"PRIi32, *(const er_t*)src ); break;
        case TYPEOF_bl_t: st_s_copy_sc( o, *(const bl_t*)src ? "true" : "false" ); break;
        case TYPEOF_tp_t:
        case TYPEOF_aware_t:
        {
            uintmax_t val = *(const tp_t*)src;
            st_s_copyf( o, "%"PRIuMAX, val );
        }
        break;

        default:
        {
            return bcore_error_push_fa( TYPEOF_conversion_error, "Converting type '#<sc_t>' into 'st_s' is not supported.", ifnameof( type ) );
        }
        break;
    }
    return 0;
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %rbx
movabsq $-0x84b14e74a9e1ff1, %rax # imm = 0xF7B4EB18B561E00F
cmpq %rax, %rsi
jg 0x114841
movabsq $-0x503db0e6e1c2e705, %rax # imm = 0xAFC24F191E3D18FB
cmpq %rax, %rsi
jg 0x11489c
movabsq $-0x5fc2af85f419929c, %rax # imm = 0xA03D507A0BE66D64
cmpq %rax, %rsi
jg 0x114941
movabsq $-0x73f6ae1ad309fd45, %rax # imm = 0x8C0951E52CF602BB
cmpq %rax, %rsi
je 0x114ab5
movabsq $-0x6bce971ace902370, %rax # imm = 0x943168E5316FDC90
cmpq %rax, %rsi
je 0x114a77
movabsq $-0x6119581ac7eacd63, %rax # imm = 0x9EE6A7E53815329D
cmpq %rax, %rsi
jne 0x114b19
movl (%rdx), %edx
jmp 0x114ab8
movabsq $0x54de8100f7c1cbe4, %rax # imm = 0x54DE8100F7C1CBE4
cmpq %rax, %rsi
jg 0x1148ed
movabsq $0x47b8ff5cd069fea0, %rax # imm = 0x47B8FF5CD069FEA0
cmpq %rax, %rsi
jg 0x11498a
movabsq $-0x84b14e74a9e1ff0, %rax # imm = 0xF7B4EB18B561E010
cmpq %rax, %rsi
je 0x114a66
movabsq $0x230abe18cdeefc99, %rax # imm = 0x230ABE18CDEEFC99
cmpq %rax, %rsi
je 0x114a66
movabsq $0x23dccbb013b0d1e5, %rax # imm = 0x23DCCBB013B0D1E5
jmp 0x1149fa
movabsq $-0x3f1363e6d8155aee, %rax # imm = 0xC0EC9C1927EAA512
cmpq %rax, %rsi
jg 0x1149ca
movabsq $-0x503db0e6e1c2e704, %rax # imm = 0xAFC24F191E3D18FC
cmpq %rax, %rsi
je 0x114ac1
movabsq $-0x4db4989f9014f113, %rax # imm = 0xB24B67606FEB0EED
cmpq %rax, %rsi
je 0x114a7c
movabsq $-0x4882601bdca6aefb, %rax # imm = 0xB77D9FE423595105
cmpq %rax, %rsi
je 0x114a6b
jmp 0x114b19
movabsq $0x69849117d3eb7d61, %rax # imm = 0x69849117D3EB7D61
cmpq %rax, %rsi
jg 0x114a04
movabsq $0x54de8100f7c1cbe5, %rax # imm = 0x54DE8100F7C1CBE5
cmpq %rax, %rsi
je 0x114a39
movabsq $0x585a3b17ca3de200, %rax # imm = 0x585A3B17CA3DE200
cmpq %rax, %rsi
je 0x114a57
movabsq $0x62367a17d02b474d, %rax # imm = 0x62367A17D02B474D
cmpq %rax, %rsi
jne 0x114b19
movsbl (%rdx), %edx
jmp 0x114afe
movabsq $-0x5fc2af85f419929b, %rax # imm = 0xA03D507A0BE66D65
cmpq %rax, %rsi
je 0x114ace
movabsq $-0x5aa4411ac4e2880e, %rax # imm = 0xA55BBEE53B1D77F2
cmpq %rax, %rsi
je 0x114a48
movabsq $-0x58737885f0577326, %rax # imm = 0xA78C877A0FA88CDA
cmpq %rax, %rsi
jne 0x114b19
cvtss2sd (%rdx), %xmm0
leaq 0x3db69(%rip), %rsi     # 0x1524ee
jmp 0x114ad9
movabsq $0x47b8ff5cd069fea1, %rax # imm = 0x47B8FF5CD069FEA1
cmpq %rax, %rsi
je 0x114a6b
movabsq $0x4fc0143367a53daf, %rax # imm = 0x4FC0143367A53DAF
cmpq %rax, %rsi
je 0x114a57
movabsq $0x510c2417c67dabeb, %rax # imm = 0x510C2417C67DABEB
cmpq %rax, %rsi
jne 0x114b19
movl (%rdx), %edx
jmp 0x114afe
movabsq $-0x3f1363e6d8155aed, %rax # imm = 0xC0EC9C1927EAA513
cmpq %rax, %rsi
je 0x114ae5
movabsq $-0x3ac242643d9c35a8, %rax # imm = 0xC53DBD9BC263CA58
cmpq %rax, %rsi
je 0x114a88
movabsq $-0x388c46b188de83fe, %rax # imm = 0xC773B94E77217C02
cmpq %rax, %rsi
je 0x114a48
jmp 0x114b19
movabsq $0x69849117d3eb7d62, %rax # imm = 0x69849117D3EB7D62
cmpq %rax, %rsi
je 0x114afb
movabsq $0x6d07f9ef5b68e8a2, %rax # imm = 0x6D07F9EF5B68E8A2
cmpq %rax, %rsi
je 0x114a48
movabsq $0x6f0b060106a30da4, %rax # imm = 0x6F0B060106A30DA4
cmpq %rax, %rsi
jne 0x114b19
movq (%rdx), %rdx
leaq 0x4252a(%rip), %rsi     # 0x156f6d
jmp 0x114aef
movq (%rdx), %rdx
leaq 0x3d333(%rip), %rsi     # 0x151d85
jmp 0x114aef
movq (%rdx), %rdx
leaq 0x3da7d(%rip), %rsi     # 0x1524de
jmp 0x114aef
movq (%rdx), %r14
jmp 0x114a9d
movq (%rdx), %rdx
leaq 0x3a11c(%rip), %rsi     # 0x14eb91
jmp 0x114aef
movzwl (%rdx), %edx
jmp 0x114ab8
movq (%rdx), %rdx
leaq 0x43fe2(%rip), %rsi     # 0x158a68
jmp 0x114aef
leaq 0x44b5e(%rip), %rax     # 0x1595ed
leaq 0x29d1b(%rip), %r14     # 0x13e7b1
cmpb $0x0, (%rdx)
cmovneq %rax, %r14
movq %r14, %rdi
callq 0xc84d7
movq %rbx, %rdi
movq %r14, %rsi
movq %rax, %rdx
callq 0x1144cd
jmp 0x114b0f
movzbl (%rdx), %edx
leaq 0x39b4b(%rip), %rsi     # 0x14e60a
jmp 0x114b05
movq %rbx, %rdi
movq %rdx, %rsi
callq 0x114440
jmp 0x114b0f
movsd (%rdx), %xmm0
leaq 0x4248d(%rip), %rsi     # 0x156f66
movq %rbx, %rdi
movb $0x1, %al
callq 0x114662
jmp 0x114b0f
movq (%rdx), %rdx
leaq 0x3d9f3(%rip), %rsi     # 0x1524e2
movq %rbx, %rdi
xorl %eax, %eax
callq 0x114662
jmp 0x114b0f
movswl (%rdx), %edx
leaq 0x43f63(%rip), %rsi     # 0x158a68
movq %rbx, %rdi
xorl %eax, %eax
callq 0x114662
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
movq %rsi, %rdi
callq 0xe0cbc
testq %rax, %rax
leaq 0x3ebc4(%rip), %rdx     # 0x1536ef
cmovneq %rax, %rdx
leaq 0x4243a(%rip), %rsi     # 0x156f70
movabsq $-0x4e68f1e683c13928, %rdi # imm = 0xB1970E197C3EC6D8
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
jmp 0xc87b0