// File: /workspace/github_cpp_makefile_star2_O1/pfnet-research[P]pml/src/test.cpp
// Function: let_test::let_test()
PML_CUSTOM_TEST(let_test, lang_feature_test) {
    using namespace ast;
    parse_test("let a = 1+2 in a + 3", "Let(a, Add(1, 2), Add(a, 3))");
    eval_test(
            make<let_expr_t>("a",
                make<add_expr_t>(
                    make<int_expr_t>(1),
                    make<int_expr_t>(2)),
                make<add_expr_t>(
                    make<var_expr_t>("a"),
                    make<int_expr_t>(3))),
            make<int_expr_t>(6));
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0xb8, %rsp
movq %rdi, %rbx
movl $0x0, 0x8(%rdi)
leaq 0x32ead(%rip), %rax     # 0x62688
movq %rax, (%rdi)
leaq 0x18(%rsp), %r14
movq %r14, -0x10(%r14)
leaq 0x1b3eb(%rip), %rsi     # 0x4abd9
leaq 0x1b3f8(%rip), %rdx     # 0x4abed
leaq 0x8(%rsp), %rdi
callq 0x11866
leaq 0x58(%rsp), %r15
movq %r15, -0x10(%r15)
leaq 0x1b3df(%rip), %rsi     # 0x4abee
leaq 0x1b3f4(%rip), %rdx     # 0x4ac0a
leaq 0x48(%rsp), %rdi
callq 0x11866
leaq 0x8(%rsp), %rsi
leaq 0x48(%rsp), %rdx
movq %rbx, %rdi
callq 0x35a02
movq 0x48(%rsp), %rdi
cmpq %r15, %rdi
je 0x2f849
movq 0x58(%rsp), %rsi
incq %rsi
callq 0x92e0
movq 0x8(%rsp), %rdi
cmpq %r14, %rdi
je 0x2f860
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x92e0
movq $0x0, 0x38(%rsp)
movl $0x20, %edi
callq 0x92d0
movabsq $0x100000001, %r14      # imm = 0x100000001
movq %r14, 0x8(%rax)
leaq 0x31238(%rip), %r15     # 0x60ac0
movq %r15, (%rax)
movq %rax, %rcx
addq $0x10, %rcx
leaq 0x31277(%rip), %r12     # 0x60b10
movq %r12, 0x10(%rax)
movl $0x1, 0x18(%rax)
movq %rax, 0x40(%rsp)
movq %rcx, 0x38(%rsp)
movq $0x0, 0x98(%rsp)
movl $0x20, %edi
callq 0x92d0
movq %r14, 0x8(%rax)
movq %r15, (%rax)
movq %rax, %rcx
addq $0x10, %rcx
movq %r12, 0x10(%rax)
movl $0x2, 0x18(%rax)
leaq 0x98(%rsp), %r8
movq %rax, 0x8(%r8)
movq %rcx, (%r8)
leaq 0x50(%rsp), %rdi
movq $0x0, -0x8(%rdi)
leaq 0x48(%rsp), %rsi
leaq 0x28(%rsp), %rdx
leaq 0x38(%rsp), %rcx
callq 0x36c98
leaq 0x90(%rsp), %rdi
movq $0x0, -0x8(%rdi)
leaq 0x1b2e7(%rip), %rcx     # 0x4ac0b
leaq 0x88(%rsp), %rsi
leaq 0x78(%rsp), %rdx
callq 0x37386
movq $0x0, 0x78(%rsp)
movl $0x20, %edi
callq 0x92d0
movq %r14, 0x8(%rax)
movq %r15, (%rax)
movq %rax, %rcx
addq $0x10, %rcx
movq %r12, 0x10(%rax)
movl $0x3, 0x18(%rax)
leaq 0x78(%rsp), %r8
movq %rax, 0x8(%r8)
movq %rcx, (%r8)
leaq 0x30(%rsp), %rdi
movq $0x0, -0x8(%rdi)
leaq 0x28(%rsp), %rsi
leaq 0x68(%rsp), %rdx
leaq 0x88(%rsp), %rcx
callq 0x37280
leaq 0x10(%rsp), %rdi
movq $0x0, -0x8(%rdi)
leaq 0x1b265(%rip), %rcx     # 0x4ac0b
leaq 0x8(%rsp), %rsi
leaq 0x68(%rsp), %rdx
leaq 0x48(%rsp), %r8
leaq 0x28(%rsp), %r9
callq 0x370ec
movups 0x8(%rsp), %xmm0
movups %xmm0, 0xa8(%rsp)
xorps %xmm0, %xmm0
movups %xmm0, 0x8(%rsp)
movl $0x20, %edi
callq 0x92d0
movq %r14, 0x8(%rax)
movq %r15, (%rax)
movq %rax, %rcx
addq $0x10, %rcx
movq %r12, 0x10(%rax)
movl $0x6, 0x18(%rax)
leaq 0x68(%rsp), %rdx
movq %rcx, (%rdx)
movq %rax, 0x8(%rdx)
leaq 0xa8(%rsp), %rsi
movq %rbx, %rdi
callq 0x35a7c
movq 0x70(%rsp), %rdi
testq %rdi, %rdi
je 0x2fa22
callq 0xaa12
movq 0xb0(%rsp), %rdi
testq %rdi, %rdi
je 0x2fa34
callq 0xaa12
movq 0x10(%rsp), %rdi
testq %rdi, %rdi
je 0x2fa43
callq 0xaa12
movq 0x30(%rsp), %rdi
testq %rdi, %rdi
je 0x2fa52
callq 0xaa12
movq 0x80(%rsp), %rdi
testq %rdi, %rdi
je 0x2fa64
callq 0xaa12
movq 0x90(%rsp), %rdi
testq %rdi, %rdi
je 0x2fa76
callq 0xaa12
movq 0x50(%rsp), %rdi
testq %rdi, %rdi
je 0x2fa85
callq 0xaa12
movq 0xa0(%rsp), %rdi
testq %rdi, %rdi
je 0x2fa97
callq 0xaa12
movq 0x40(%rsp), %rdi
testq %rdi, %rdi
je 0x2faa6
callq 0xaa12
addq $0xb8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
movq %rax, %rbx
movq 0x70(%rsp), %rdi
testq %rdi, %rdi
je 0x2facc
callq 0xaa12
jmp 0x2facc
movq %rax, %rbx
movq 0xb0(%rsp), %rdi
testq %rdi, %rdi
je 0x2fade
callq 0xaa12
movq 0x10(%rsp), %rdi
testq %rdi, %rdi
je 0x2faf2
callq 0xaa12
jmp 0x2faf2
movq %rax, %rbx
movq 0x30(%rsp), %rdi
testq %rdi, %rdi
je 0x2fb06
callq 0xaa12
jmp 0x2fb06
movq %rax, %rbx
movq 0x80(%rsp), %rdi
testq %rdi, %rdi
je 0x2fb1d
callq 0xaa12
jmp 0x2fb1d
movq %rax, %rbx
movq 0x90(%rsp), %rdi
testq %rdi, %rdi
je 0x2fb34
callq 0xaa12
jmp 0x2fb34
movq %rax, %rbx
movq 0x50(%rsp), %rdi
testq %rdi, %rdi
je 0x2fb48
callq 0xaa12
jmp 0x2fb48
movq %rax, %rbx
movq 0xa0(%rsp), %rdi
testq %rdi, %rdi
je 0x2fb5f
callq 0xaa12
jmp 0x2fb5f
movq %rax, %rbx
movq 0x40(%rsp), %rdi
testq %rdi, %rdi
je 0x2fbad
callq 0xaa12
jmp 0x2fbad
jmp 0x2fbaa
movq %rax, %rbx
movq 0x48(%rsp), %rdi
cmpq %r15, %rdi
je 0x2fb91
movq 0x58(%rsp), %rsi
incq %rsi
callq 0x92e0
jmp 0x2fb91
movq %rax, %rbx
movq 0x8(%rsp), %rdi
cmpq %r14, %rdi
je 0x2fbad
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x92e0
jmp 0x2fbad
movq %rax, %rbx
movq %rbx, %rdi
callq 0x94e0
nop