// File: /workspace/github_c_makefile_star2_O2/johsteffens[P]beth/xoico/src/xoico.xo.c
// Function: xoico_compiler_s_get_type_member_function_info
bl_t xoico_compiler_s_get_type_member_function_info( const xoico_compiler_s* o, tp_t type, tp_t name, xoico_compiler_element_info_s* info )
{
    // xoico_compiler.x:596:1
    
    const xoico* xoico_item = xoico_compiler_s_get_const_item(o,type );
    if( !xoico_item )
    {
        xoico_item =((const xoico*)( xoico_compiler_s_get_group(((xoico_compiler_s*)(o)),type )));
        if( !xoico_item ) return  false;
    }
    
    bl_t success = false;
    ASSERT( info );
    info->type_info.item = ((xoico*)(xoico_item));
    
    if( xoico_item->_ == ((tp_t)(TYPEOF_xoico_stamp_s)) )
    {
        const xoico_stamp_s* stamp = ((const xoico_stamp_s*)(xoico_item));
        const bcore_self_s* self = stamp->self;
        const bcore_self_item_s* self_item = NULL; // returns NULL in case of no match
    
        if( ( info->func = ((xoico_func_s*)(xoico_stamp_s_get_traitline_func_from_name(stamp,name ))) ) ) /// trait-line function
        {
            success = true;
        }
        else if( ( self_item = bcore_self_s_get_item_by_name(self,name ) ) )
        {
            if( self_item->caps == BCORE_CAPS_EXTERNAL_FUNC )
            {
                info->func = ((xoico_func_s*)(xoico_stamp_s_get_func_from_name(stamp,name )));
                ASSERT( info->func );
                success = true;
            }
        }
    }
    else if( xoico_item->_ == ((tp_t)(TYPEOF_xoico_group_s)) )
    {
        const xoico_group_s* group = ((xoico_group_s*)(xoico_item));
        info->func = ((xoico_func_s*)(xoico_group_s_get_traitline_func_from_name(group,name )));
        if( info->func ) success = true;
    }
    
    if( !success )
    {
        if( xoico_compiler_s_is_func(o,name ) )
        {
            info->func = xoico_compiler_s_get_func(((xoico_compiler_s*)(o)),name );
            success = true;
        }
    }
    
    return  success;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rcx, %rbx
movq %rdx, %r14
movq %rsi, %r13
movq %rdi, %r15
callq 0x162bb
testq %rax, %rax
jne 0x1c8e5
movq %r15, %rdi
movq %r13, %rsi
callq 0x1393c
testq %rax, %rax
je 0x1c9fb
movq %rax, %r12
testq %rbx, %rbx
jne 0x1c916
leaq 0x8dd53(%rip), %rdi     # 0xaa647
leaq 0x90848(%rip), %rsi     # 0xad143
leaq 0x90846(%rip), %rdx     # 0xad148
leaq 0x8d987(%rip), %rcx     # 0xaa290
movl $0x185d, %r8d           # imm = 0x185D
xorl %eax, %eax
callq 0x5ffac
movq %r12, 0x40(%rbx)
movq (%r12), %rax
movabsq $0xc561a9d047fe9d3, %rcx # imm = 0xC561A9D047FE9D3
cmpq %rcx, %rax
je 0x1c9bd
movabsq $0x12d01d78049fae7, %rcx # imm = 0x12D01D78049FAE7
cmpq %rcx, %rax
jne 0x1c9d4
movq 0x50(%r12), %r13
movq %r12, %rdi
movq %r14, %rsi
callq 0x1792c
movq %rax, 0x48(%rbx)
movb $0x1, %bpl
testq %rax, %rax
jne 0x1c9fd
movq %r13, %rdi
movq %r14, %rsi
callq 0x6392e
testq %rax, %rax
je 0x1c9d4
cmpl $0xe, 0x10(%rax)
jne 0x1c9d4
addq $0x58, %r12
movq %r12, %rdi
movq %r14, %rsi
callq 0x11c0d
movq %rax, 0x48(%rbx)
testq %rax, %rax
jne 0x1c9fd
leaq 0x8dcae(%rip), %rdi     # 0xaa647
leaq 0x907d7(%rip), %rsi     # 0xad177
leaq 0x907a1(%rip), %rdx     # 0xad148
leaq 0x8d8e2(%rip), %rcx     # 0xaa290
movl $0x186f, %r8d           # imm = 0x186F
xorl %eax, %eax
callq 0x5ffac
jmp 0x1c9fd
movq %r12, %rdi
movq %r14, %rsi
callq 0x13993
movq %rax, 0x48(%rbx)
movb $0x1, %bpl
testq %rax, %rax
jne 0x1c9fd
leaq 0xa0(%r15), %rdi
movq %r14, %rsi
callq 0x68f9b
testb %al, %al
je 0x1c9fb
movq %r15, %rdi
movq %r14, %rsi
callq 0x1c2e0
movq %rax, 0x48(%rbx)
movb $0x1, %bpl
jmp 0x1c9fd
xorl %ebp, %ebp
movl %ebp, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq