// File: /workspace/github_c_makefile_star2_O0/janet-lang[P]janet/src/core/compile.c
// Function: janet_def_addflags
void janet_def_addflags(JanetFuncDef *def) {
    int32_t set_flags = 0;
    int32_t unset_flags = 0;
    /* pos checks */
    if (def->name)            set_flags |= JANET_FUNCDEF_FLAG_HASNAME;
    if (def->source)          set_flags |= JANET_FUNCDEF_FLAG_HASSOURCE;
    if (def->defs)            set_flags |= JANET_FUNCDEF_FLAG_HASDEFS;
    if (def->environments)    set_flags |= JANET_FUNCDEF_FLAG_HASENVS;
    if (def->sourcemap)       set_flags |= JANET_FUNCDEF_FLAG_HASSOURCEMAP;
    if (def->closure_bitset)  set_flags |= JANET_FUNCDEF_FLAG_HASCLOBITSET;
    /* negative checks */
    if (!def->name)           unset_flags |= JANET_FUNCDEF_FLAG_HASNAME;
    if (!def->source)         unset_flags |= JANET_FUNCDEF_FLAG_HASSOURCE;
    if (!def->defs)           unset_flags |= JANET_FUNCDEF_FLAG_HASDEFS;
    if (!def->environments)   unset_flags |= JANET_FUNCDEF_FLAG_HASENVS;
    if (!def->sourcemap)      unset_flags |= JANET_FUNCDEF_FLAG_HASSOURCEMAP;
    if (!def->closure_bitset) unset_flags |= JANET_FUNCDEF_FLAG_HASCLOBITSET;
    /* Update flags */
    def->flags |= set_flags;
    def->flags &= ~unset_flags;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
movq %rdi, -0x8(%rbp)
movl $0x0, -0xc(%rbp)
movl $0x0, -0x10(%rbp)
movq -0x8(%rbp), %rax
cmpq $0x0, 0x48(%rax)
je 0x2322c
movl -0xc(%rbp), %eax
orl $0x80000, %eax          # imm = 0x80000
movl %eax, -0xc(%rbp)
movq -0x8(%rbp), %rax
cmpq $0x0, 0x40(%rax)
je 0x23242
movl -0xc(%rbp), %eax
orl $0x100000, %eax         # imm = 0x100000
movl %eax, -0xc(%rbp)
movq -0x8(%rbp), %rax
cmpq $0x0, 0x20(%rax)
je 0x23258
movl -0xc(%rbp), %eax
orl $0x200000, %eax         # imm = 0x200000
movl %eax, -0xc(%rbp)
movq -0x8(%rbp), %rax
cmpq $0x0, 0x10(%rax)
je 0x2326e
movl -0xc(%rbp), %eax
orl $0x400000, %eax         # imm = 0x400000
movl %eax, -0xc(%rbp)
movq -0x8(%rbp), %rax
cmpq $0x0, 0x38(%rax)
je 0x23284
movl -0xc(%rbp), %eax
orl $0x800000, %eax         # imm = 0x800000
movl %eax, -0xc(%rbp)
movq -0x8(%rbp), %rax
cmpq $0x0, 0x30(%rax)
je 0x2329a
movl -0xc(%rbp), %eax
orl $0x2000000, %eax        # imm = 0x2000000
movl %eax, -0xc(%rbp)
movq -0x8(%rbp), %rax
cmpq $0x0, 0x48(%rax)
jne 0x232b0
movl -0x10(%rbp), %eax
orl $0x80000, %eax          # imm = 0x80000
movl %eax, -0x10(%rbp)
movq -0x8(%rbp), %rax
cmpq $0x0, 0x40(%rax)
jne 0x232c6
movl -0x10(%rbp), %eax
orl $0x100000, %eax         # imm = 0x100000
movl %eax, -0x10(%rbp)
movq -0x8(%rbp), %rax
cmpq $0x0, 0x20(%rax)
jne 0x232dc
movl -0x10(%rbp), %eax
orl $0x200000, %eax         # imm = 0x200000
movl %eax, -0x10(%rbp)
movq -0x8(%rbp), %rax
cmpq $0x0, 0x10(%rax)
jne 0x232f2
movl -0x10(%rbp), %eax
orl $0x400000, %eax         # imm = 0x400000
movl %eax, -0x10(%rbp)
movq -0x8(%rbp), %rax
cmpq $0x0, 0x38(%rax)
jne 0x23308
movl -0x10(%rbp), %eax
orl $0x800000, %eax         # imm = 0x800000
movl %eax, -0x10(%rbp)
movq -0x8(%rbp), %rax
cmpq $0x0, 0x30(%rax)
jne 0x2331e
movl -0x10(%rbp), %eax
orl $0x2000000, %eax        # imm = 0x2000000
movl %eax, -0x10(%rbp)
movl -0xc(%rbp), %ecx
movq -0x8(%rbp), %rax
orl 0x58(%rax), %ecx
movl %ecx, 0x58(%rax)
movl -0x10(%rbp), %ecx
xorl $-0x1, %ecx
movq -0x8(%rbp), %rax
andl 0x58(%rax), %ecx
movl %ecx, 0x58(%rax)
popq %rbp
retq
nopl (%rax)