// File: /workspace/github_c_makefile_star2_O3/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 0x109908
movabsq $-0x503db0e6e1c2e705, %rax # imm = 0xAFC24F191E3D18FB
cmpq %rax, %rsi
jg 0x109963
movabsq $-0x5fc2af85f419929c, %rax # imm = 0xA03D507A0BE66D64
cmpq %rax, %rsi
jg 0x109a08
movabsq $-0x73f6ae1ad309fd45, %rax # imm = 0x8C0951E52CF602BB
cmpq %rax, %rsi
je 0x109b7c
movabsq $-0x6bce971ace902370, %rax # imm = 0x943168E5316FDC90
cmpq %rax, %rsi
je 0x109b3e
movabsq $-0x6119581ac7eacd63, %rax # imm = 0x9EE6A7E53815329D
cmpq %rax, %rsi
jne 0x109be0
movl (%rdx), %edx
jmp 0x109b7f
movabsq $0x54de8100f7c1cbe4, %rax # imm = 0x54DE8100F7C1CBE4
cmpq %rax, %rsi
jg 0x1099b4
movabsq $0x47b8ff5cd069fea0, %rax # imm = 0x47B8FF5CD069FEA0
cmpq %rax, %rsi
jg 0x109a51
movabsq $-0x84b14e74a9e1ff0, %rax # imm = 0xF7B4EB18B561E010
cmpq %rax, %rsi
je 0x109b2d
movabsq $0x230abe18cdeefc99, %rax # imm = 0x230ABE18CDEEFC99
cmpq %rax, %rsi
je 0x109b2d
movabsq $0x23dccbb013b0d1e5, %rax # imm = 0x23DCCBB013B0D1E5
jmp 0x109ac1
movabsq $-0x3f1363e6d8155aee, %rax # imm = 0xC0EC9C1927EAA512
cmpq %rax, %rsi
jg 0x109a91
movabsq $-0x503db0e6e1c2e704, %rax # imm = 0xAFC24F191E3D18FC
cmpq %rax, %rsi
je 0x109b88
movabsq $-0x4db4989f9014f113, %rax # imm = 0xB24B67606FEB0EED
cmpq %rax, %rsi
je 0x109b43
movabsq $-0x4882601bdca6aefb, %rax # imm = 0xB77D9FE423595105
cmpq %rax, %rsi
je 0x109b32
jmp 0x109be0
movabsq $0x69849117d3eb7d61, %rax # imm = 0x69849117D3EB7D61
cmpq %rax, %rsi
jg 0x109acb
movabsq $0x54de8100f7c1cbe5, %rax # imm = 0x54DE8100F7C1CBE5
cmpq %rax, %rsi
je 0x109b00
movabsq $0x585a3b17ca3de200, %rax # imm = 0x585A3B17CA3DE200
cmpq %rax, %rsi
je 0x109b1e
movabsq $0x62367a17d02b474d, %rax # imm = 0x62367A17D02B474D
cmpq %rax, %rsi
jne 0x109be0
movsbl (%rdx), %edx
jmp 0x109bc5
movabsq $-0x5fc2af85f419929b, %rax # imm = 0xA03D507A0BE66D65
cmpq %rax, %rsi
je 0x109b95
movabsq $-0x5aa4411ac4e2880e, %rax # imm = 0xA55BBEE53B1D77F2
cmpq %rax, %rsi
je 0x109b0f
movabsq $-0x58737885f0577326, %rax # imm = 0xA78C877A0FA88CDA
cmpq %rax, %rsi
jne 0x109be0
cvtss2sd (%rdx), %xmm0
leaq 0x3dac8(%rip), %rsi     # 0x147514
jmp 0x109ba0
movabsq $0x47b8ff5cd069fea1, %rax # imm = 0x47B8FF5CD069FEA1
cmpq %rax, %rsi
je 0x109b32
movabsq $0x4fc0143367a53daf, %rax # imm = 0x4FC0143367A53DAF
cmpq %rax, %rsi
je 0x109b1e
movabsq $0x510c2417c67dabeb, %rax # imm = 0x510C2417C67DABEB
cmpq %rax, %rsi
jne 0x109be0
movl (%rdx), %edx
jmp 0x109bc5
movabsq $-0x3f1363e6d8155aed, %rax # imm = 0xC0EC9C1927EAA513
cmpq %rax, %rsi
je 0x109bac
movabsq $-0x3ac242643d9c35a8, %rax # imm = 0xC53DBD9BC263CA58
cmpq %rax, %rsi
je 0x109b4f
movabsq $-0x388c46b188de83fe, %rax # imm = 0xC773B94E77217C02
cmpq %rax, %rsi
je 0x109b0f
jmp 0x109be0
movabsq $0x69849117d3eb7d62, %rax # imm = 0x69849117D3EB7D62
cmpq %rax, %rsi
je 0x109bc2
movabsq $0x6d07f9ef5b68e8a2, %rax # imm = 0x6D07F9EF5B68E8A2
cmpq %rax, %rsi
je 0x109b0f
movabsq $0x6f0b060106a30da4, %rax # imm = 0x6F0B060106A30DA4
cmpq %rax, %rsi
jne 0x109be0
movq (%rdx), %rdx
leaq 0x4248b(%rip), %rsi     # 0x14bf95
jmp 0x109bb6
movq (%rdx), %rdx
leaq 0x3d292(%rip), %rsi     # 0x146dab
jmp 0x109bb6
movq (%rdx), %rdx
leaq 0x3d9dc(%rip), %rsi     # 0x147504
jmp 0x109bb6
movq (%rdx), %r14
jmp 0x109b64
movq (%rdx), %rdx
leaq 0x3a095(%rip), %rsi     # 0x143bd1
jmp 0x109bb6
movzwl (%rdx), %edx
jmp 0x109b7f
movq (%rdx), %rdx
leaq 0x43f73(%rip), %rsi     # 0x14dac0
jmp 0x109bb6
leaq 0x44af7(%rip), %rax     # 0x14e64d
leaq 0x29c54(%rip), %r14     # 0x1337b1
cmpb $0x0, (%rdx)
cmovneq %rax, %r14
movq %r14, %rdi
callq 0xbe963
movq %rbx, %rdi
movq %r14, %rsi
movq %rax, %rdx
callq 0x10958f
jmp 0x109bd6
movzbl (%rdx), %edx
leaq 0x39ac4(%rip), %rsi     # 0x14364a
jmp 0x109bcc
movq %rbx, %rdi
movq %rdx, %rsi
callq 0x1094fa
jmp 0x109bd6
movsd (%rdx), %xmm0
leaq 0x423ee(%rip), %rsi     # 0x14bf8e
movq %rbx, %rdi
movb $0x1, %al
callq 0x109729
jmp 0x109bd6
movq (%rdx), %rdx
leaq 0x3d952(%rip), %rsi     # 0x147508
movq %rbx, %rdi
xorl %eax, %eax
callq 0x109729
jmp 0x109bd6
movswl (%rdx), %edx
leaq 0x43ef4(%rip), %rsi     # 0x14dac0
movq %rbx, %rdi
xorl %eax, %eax
callq 0x109729
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
movq %rsi, %rdi
callq 0xd6ec4
testq %rax, %rax
leaq 0x3eb23(%rip), %rdx     # 0x148715
cmovneq %rax, %rdx
leaq 0x4239b(%rip), %rsi     # 0x14bf98
movabsq $-0x4e68f1e683c13928, %rdi # imm = 0xB1970E197C3EC6D8
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
jmp 0xbec3c