// File: /workspace/github_c_makefile_star2_O1/BernardTatin[P]s7sh/s7.c
// Function: sublet_1
static s7_pointer sublet_1(s7_scheme *sc, s7_pointer e, s7_pointer bindings, s7_pointer caller)
    {
        s7_pointer new_e;
        if (e == sc->rootlet)
            new_e = new_frame_in_env(sc, sc->nil);
        else new_e = new_frame_in_env(sc, e);
        set_all_methods(new_e, e);

        if (!is_null(bindings))
        {
            s7_pointer x;
            sc->temp3 = new_e;

            for (x = bindings; is_pair(x); x = cdr(x))
            {
                s7_pointer p, sym, val;

                p = car(x);
                switch (type(p))
                {
                    /* should this insist on one style of field arg?  i.e. (cons sym val) throughout, or :sym val etc? */
                    case T_SYMBOL:
                        if (is_keyword(p))
                            sym = keyword_symbol(p);
                        else sym = p;
                        if (!is_pair(cdr(x)))
                            s7_error(sc, sc->error_symbol, set_elist_3(sc, value_is_missing_string, caller, car(x)));
                        x = cdr(x);
                        val = car(x);
                        break;

                    case T_PAIR:
                        sym = car(p);
                        if (!is_symbol(sym))
                            return(wrong_type_argument_with_type(sc, caller, 1 + position_of(x, bindings), p, a_symbol_string));
                        if (is_keyword(sym))
                            sym = keyword_symbol(sym);
                        val = cdr(p);
                        break;

                    case T_LET:
                        append_let(sc, new_e, check_c_obj_env(sc, p, caller));
                        continue;

                    default:
                        return(wrong_type_argument_with_type(sc, caller, 1 + position_of(x, bindings), p, a_symbol_string));
                }

                if (is_constant_symbol(sc, sym))
                    return(wrong_type_argument_with_type(sc, caller, 1 + position_of(x, bindings), sym, a_non_constant_symbol_string));
                if ((is_slot(global_slot(sym))) &&
                        (is_syntax(slot_value(global_slot(sym)))))
                    return(wrong_type_argument_with_type(sc, caller, 2, sym, wrap_string(sc, "a non-syntactic name", 20)));

                /* here we know new_e is a let and is not rootlet */
                make_slot_1(sc, new_e, sym, val);
                if (sym == sc->let_ref_fallback_symbol)
                    set_has_let_ref_fallback(new_e);
                else
                {
                    if (sym == sc->let_set_fallback_symbol)
                        set_has_let_set_fallback(new_e);
                }
            }
            sc->temp3 = sc->nil;
        }
        return(new_e);
    }

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %rcx, 0x8(%rsp)
movq %rdx, %r13
movq %rsi, %r14
movq %rdi, %rbx
cmpq %rsi, 0x150(%rdi)
je 0xb401
movq 0x90(%rbx), %rax
movq %r14, %r15
jmp 0xb40f
movq 0x90(%rbx), %rax
movq 0x110(%rbx), %r15
cmpq 0x98(%rbx), %rax
ja 0xb420
movq %rbx, %rdi
callq 0xb389
movq 0x90(%rbx), %rax
leaq -0x8(%rax), %rcx
movq %rcx, 0x90(%rbx)
movq -0x8(%rax), %r12
movq $0x20001c, (%r12)       # imm = 0x20001C
movq 0x250(%rbx), %rax
incq %rax
movq %rax, 0x250(%rbx)
movq %rax, 0x18(%r12)
movq $0x0, 0x8(%r12)
movq %r15, 0x10(%r12)
movq (%r14), %rax
andl $0x4c000000, %eax       # imm = 0x4C000000
orq %rax, (%r12)
cmpq %r13, 0x110(%rbx)
je 0xb80f
movq %r12, 0x508(%rbx)
movq %r13, 0x10(%rsp)
cmpb $0x1, (%r13)
jne 0xb7fb
movq 0x10(%rsp), %r15
movq 0x8(%r15), %rbp
movzbl (%rbp), %eax
cmpl $0x1, %eax
je 0xb543
cmpl $0x1c, %eax
je 0xb51b
cmpl $0xa, %eax
jne 0xb65c
testb $-0x80, 0x6(%rbp)
movq %rbp, %r14
je 0xb4cb
movq 0x8(%rbp), %rax
movq 0x20(%rax), %rax
movq 0x18(%rax), %r14
movq 0x10(%r15), %rax
cmpb $0x1, (%rax)
je 0xb511
movq 0xea8(%rbx), %rsi
movq 0x14a9ce(%rip), %rax    # 0x155eb0
movq 0x6e8(%rbx), %rcx
movq %rax, 0x8(%rcx)
movq 0x10(%rcx), %rax
movq 0x8(%rsp), %rcx
movq %rcx, 0x8(%rax)
movq 0x10(%rax), %rax
movq %rbp, 0x8(%rax)
movq 0x6e8(%rbx), %rdx
movq %rbx, %rdi
callq 0x3b366
movq 0x10(%r15), %r15
leaq 0x8(%r15), %rbp
jmp 0xb568
movq %rbx, %rdi
movq %rbp, %rsi
movq 0x8(%rsp), %rdx
callq 0x95352
movq %rbx, %rdi
movq %r12, %rsi
movq %rax, %rdx
callq 0x950f5
movl $0x4, %ecx
jmp 0xb7d8
movq 0x8(%rbp), %r14
cmpb $0xa, (%r14)
jne 0xb6ba
testb $-0x80, 0x6(%r14)
je 0xb564
movq 0x8(%r14), %rax
movq 0x20(%rax), %rax
movq 0x18(%rax), %r14
addq $0x10, %rbp
testb $0x1, 0x3(%r14)
jne 0xb678
movq (%rbp), %rcx
testb $0x1, 0x6(%r14)
je 0xb5f2
movq 0x8(%rbx), %rdx
movq 0x18(%rdx), %rdi
movq 0x20(%r14), %rsi
movl $0x18, %eax
cmpq %rsi, %rdi
je 0xb5df
jle 0xb5a3
movq 0x10(%rdx), %rdx
movq 0x18(%rdx), %rdi
cmpq %rdi, %rsi
jl 0xb596
cmpq %rsi, %rdi
je 0xb5df
movl $0x10, %eax
cmpb $0x1c, (%rdx)
jne 0xb5df
movq 0x8(%rdx), %rdi
testq %rdi, %rdi
sete %r8b
je 0xb5d1
cmpq %r14, 0x8(%rdi)
je 0xb5cb
movq 0x18(%rdi), %rdi
jmp 0xb5b6
xorl %r8d, %r8d
movq %rdi, %rsi
testb %r8b, %r8b
je 0xb5e3
movq 0x10(%rdx), %rdx
cmpb $0x1c, (%rdx)
je 0xb5b2
movq (%r14,%rax), %rsi
cmpb $0x20, (%rsi)
jne 0xb5f2
testb $0x1, 0x3(%rsi)
jne 0xb678
movq 0x10(%r14), %rax
cmpb $0x20, (%rax)
jne 0xb74b
movq 0x10(%rax), %rax
cmpb $0x9, (%rax)
jne 0xb74b
movq 0x8(%rsp), %rax
movq 0x8(%rax), %rsi
movq 0x143344(%rip), %rdx    # 0x14e960
movq 0x140(%rbx), %r8
movq 0x820(%rbx), %rax
movslq 0x7dc(%rbx), %rcx
movq (%rax,%rcx,8), %r9
leal 0x1(%rcx), %eax
andl $0x7, %eax
movl %eax, 0x7dc(%rbx)
leaq 0x1078d9(%rip), %rax    # 0x112f21
movq %rax, 0x10(%r9)
movq $0x14, 0x8(%r9)
movq %rbx, %rdi
jmp 0xb7c8
movq 0x10(%rsp), %rcx
movl $0x2, %eax
cmpq %rcx, %r15
je 0xb6d4
movq 0x10(%rcx), %rcx
incl %eax
cmpq %r15, %rcx
jne 0xb66b
jmp 0xb6d4
movq 0x10(%rsp), %rcx
movl $0x2, %eax
cmpq %rcx, %r15
je 0xb692
movq 0x10(%rcx), %rcx
incl %eax
cmpq %r15, %rcx
jne 0xb687
movq 0x8(%rsp), %rcx
movq 0x8(%rcx), %r13
movslq %eax, %rbp
cmpl $0x7ff, %ebp            # imm = 0x7FF
ja 0xb77b
leaq 0x14329f(%rip), %rax    # 0x14e950
movq (%rax,%rbp,8), %rdx
jmp 0xb7b4
movq 0x10(%rsp), %rcx
movl $0x2, %eax
cmpq %rcx, %r15
je 0xb6d4
movq 0x10(%rcx), %rcx
incl %eax
cmpq %r15, %rcx
jne 0xb6c9
movq 0x8(%rsp), %rcx
movq 0x8(%rcx), %r14
movslq %eax, %r13
cmpl $0x7ff, %r13d           # imm = 0x7FF
ja 0xb6f6
leaq 0x143260(%rip), %rax    # 0x14e950
movq (%rax,%r13,8), %rdx
jmp 0xb72f
movq 0x90(%rbx), %rax
cmpq 0x98(%rbx), %rax
ja 0xb70e
movq %rbx, %rdi
callq 0xb389
movq 0x90(%rbx), %rax
leaq -0x8(%rax), %rcx
movq %rcx, 0x90(%rbx)
movq -0x8(%rax), %rdx
movq $0xb, (%rdx)
movq %r13, 0x8(%rdx)
movq 0x140(%rbx), %r8
movq 0x147223(%rip), %r9     # 0x152960
movq %rbx, %rdi
movq %r14, %rsi
movq %rbp, %rcx
jmp 0xb7cb
movq %rbx, %rdi
movq %r12, %rsi
movq %r14, %rdx
callq 0xb169
cmpq 0x1228(%rbx), %r14
je 0xb7ef
xorl %ecx, %ecx
movb $0x1, %al
cmpq 0x1238(%rbx), %r14
jne 0xb7da
orb $0x8, 0x3(%r12)
jmp 0xb7da
movq 0x90(%rbx), %rax
cmpq 0x98(%rbx), %rax
ja 0xb793
movq %rbx, %rdi
callq 0xb389
movq 0x90(%rbx), %rax
leaq -0x8(%rax), %rcx
movq %rcx, 0x90(%rbx)
movq -0x8(%rax), %rdx
movq $0xb, (%rdx)
movq %rbp, 0x8(%rdx)
movq 0x140(%rbx), %r8
movq 0x14a6f6(%rip), %r9     # 0x155eb8
movq %rbx, %rdi
movq %r13, %rsi
movq %r14, %rcx
callq 0xb31d
movq %rax, %r13
movl $0x1, %ecx
xorl %eax, %eax
testb $0x3, %cl
jne 0xb80b
movq 0x10(%r15), %r15
cmpb $0x1, (%r15)
je 0xb497
jmp 0xb7fb
orb $0x4, 0x3(%r12)
xorl %ecx, %ecx
movb $0x1, %al
jmp 0xb7da
movq 0x110(%rbx), %rax
movq %rax, 0x508(%rbx)
movb $0x1, %al
testb %al, %al
je 0xb812
movq %r12, %r13
movq %r13, %rax
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq