// File: /workspace/github_cpp_makefile_star2_O2/pfnet-research[P]pml/src/test.cpp
// Function: simple_type_let::simple_type_let()
PML_TEST(simple_type_let) {
    // let a = 12 in 42
    assert_eq(
        *simty::simple_typing(ast::let_expr_t {
            "a",
            make<ast::int_expr_t>(12),
            make<ast::int_expr_t>(42)
        }).ok(),
        simty::int_type_t{});

    // let a = 12 in a
    assert_eq(
        *simty::simple_typing(ast::let_expr_t {
            "a",
            make<ast::int_expr_t>(12),
            make<ast::var_expr_t>("a")
        }).ok(),
        simty::int_type_t{});
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x108, %rsp            # imm = 0x108
movq %rdi, %rbx
andl $0x0, 0x8(%rdi)
leaq 0x32cc3(%rip), %rax     # 0x5bbe0
movq %rax, (%rdi)
leaq 0x13350(%rip), %rsi     # 0x3c277
leaq 0x38(%rsp), %rdi
leaq 0x7(%rsp), %rdx
callq 0xeb2e
leaq 0xc(%rsp), %rsi
movl $0xc, (%rsi)
leaq 0x20(%rsp), %rdi
callq 0xbc7c
leaq 0xb8(%rsp), %r15
leaq 0x28(%rsp), %r14
movaps -0x8(%r14), %xmm0
movaps %xmm0, -0x8(%r15)
xorps %xmm0, %xmm0
movaps %xmm0, -0x8(%r14)
leaq 0x8(%rsp), %rsi
movl $0x2a, (%rsi)
leaq 0x10(%rsp), %rdi
callq 0xbc7c
leaq 0xa8(%rsp), %r13
leaq 0x18(%rsp), %r12
movaps -0x8(%r12), %xmm0
movaps %xmm0, -0x8(%r13)
xorps %xmm0, %xmm0
movaps %xmm0, -0x8(%r12)
leaq 0xc0(%rsp), %rdi
leaq 0x38(%rsp), %rsi
leaq 0xb0(%rsp), %rdx
leaq 0xa0(%rsp), %rcx
callq 0x1cc6e
leaq 0x58(%rsp), %rdi
leaq 0xc0(%rsp), %rsi
callq 0x222d4
leaq 0x58(%rsp), %rdi
callq 0x223e4
movq (%rax), %rsi
leaq 0x32568(%rip), %rbp     # 0x5b550
leaq 0x30(%rsp), %rdx
movq %rbp, (%rdx)
movq %rbx, %rdi
callq 0x2f09e
leaq 0x58(%rsp), %rdi
callq 0x13c86
leaq 0xc0(%rsp), %rdi
callq 0x1ccb4
movq %r13, %rdi
callq 0xa248
movq %r12, %rdi
callq 0xa248
movq %r15, %rdi
callq 0xa248
movq %r14, %rdi
callq 0xa248
leaq 0x38(%rsp), %rdi
callq 0x9130
leaq 0x13237(%rip), %rsi     # 0x3c277
leaq 0x38(%rsp), %rdi
leaq 0x8(%rsp), %rdx
callq 0xeb2e
leaq 0xc(%rsp), %rsi
movl $0xc, (%rsi)
leaq 0x20(%rsp), %rdi
callq 0xbc7c
leaq 0x98(%rsp), %r15
leaq 0x28(%rsp), %r14
movaps -0x8(%r14), %xmm0
movaps %xmm0, -0x8(%r15)
xorps %xmm0, %xmm0
movaps %xmm0, -0x8(%r14)
leaq 0x131ed(%rip), %rsi     # 0x3c277
leaq 0x10(%rsp), %rdi
callq 0x2b094
leaq 0x88(%rsp), %r13
leaq 0x18(%rsp), %r12
movaps -0x8(%r12), %xmm0
movaps %xmm0, -0x8(%r13)
xorps %xmm0, %xmm0
movaps %xmm0, -0x8(%r12)
leaq 0xc0(%rsp), %rdi
leaq 0x38(%rsp), %rsi
leaq 0x90(%rsp), %rdx
leaq 0x80(%rsp), %rcx
callq 0x1cc6e
leaq 0x58(%rsp), %rdi
leaq 0xc0(%rsp), %rsi
callq 0x222d4
leaq 0x58(%rsp), %rdi
callq 0x223e4
movq (%rax), %rsi
leaq 0x30(%rsp), %rdx
movq %rbp, (%rdx)
movq %rbx, %rdi
callq 0x2f09e
leaq 0x58(%rsp), %rdi
callq 0x13c86
leaq 0xc0(%rsp), %rdi
callq 0x1ccb4
movq %r13, %rdi
callq 0xa248
movq %r12, %rdi
callq 0xa248
movq %r15, %rdi
callq 0xa248
movq %r14, %rdi
callq 0xa248
leaq 0x38(%rsp), %rdi
callq 0x9130
addq $0x108, %rsp            # imm = 0x108
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0x29169
jmp 0x29169
jmp 0x29178
jmp 0x2918a
jmp 0x2919f
jmp 0x291c4
jmp 0x291c9
jmp 0x29169
movq %rax, %rbx
leaq 0x58(%rsp), %rdi
callq 0x13c86
jmp 0x2917b
movq %rax, %rbx
leaq 0xc0(%rsp), %rdi
callq 0x1ccb4
jmp 0x2918d
movq %rax, %rbx
movq %r13, %rdi
callq 0xa248
movq %r12, %rdi
callq 0xa248
jmp 0x291a2
movq %rax, %rbx
movq %r15, %rdi
callq 0xa248
movq %r14, %rdi
callq 0xa248
leaq 0x38(%rsp), %rdi
callq 0x9130
movq %rbx, %rdi
callq 0x94d0
movq %rax, %rbx
jmp 0x291b2
movq %rax, %rbx
jmp 0x291bc