// File: pfnet-research[P]pml/src/test.cpp
// Function: simple_type_logical::simple_type_logical()
PML_TEST(simple_type_logical) {
    assert_eq(
        *simty::simple_typing(ast::neg_expr_t{
            make<ast::bool_expr_t>(true)}).ok(),
        simty::bool_type_t{});

    assert_eq(
        *simty::simple_typing(ast::eq_expr_t{
            make<ast::int_expr_t>(42),
            make<ast::int_expr_t>(32)}).ok(),
        simty::bool_type_t{});

    assert_eq(
        *simty::simple_typing(ast::leq_expr_t {
            make<ast::int_expr_t>(32),
            make<ast::int_expr_t>(12)}).ok(),
        simty::bool_type_t{});

    assert_eq(
        *simty::simple_typing(ast::and_expr_t {
            make<ast::bool_expr_t>(true),
            make<ast::bool_expr_t>(false)}).ok(),
        simty::bool_type_t{});

    assert_eq(
        *simty::simple_typing(ast::or_expr_t {
            make<ast::bool_expr_t>(true),
            make<ast::bool_expr_t>(false)}).ok(),
        simty::bool_type_t{});
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x3d0, %rsp            # imm = 0x3D0
movq %rdi, -0x8(%rbp)
movq -0x8(%rbp), %rdi
movq %rdi, -0x330(%rbp)
callq 0x71f20
movq -0x330(%rbp), %rax
leaq 0x7690b(%rip), %rcx     # 0xe6b48
movq %rcx, (%rax)
movb $0x1, -0x69(%rbp)
leaq -0x68(%rbp), %rdi
leaq -0x69(%rbp), %rsi
callq 0x67fd0
jmp 0x70253
leaq -0x58(%rbp), %rdi
movq %rdi, -0x338(%rbp)
leaq -0x68(%rbp), %rsi
callq 0x12f10
movq -0x338(%rbp), %rsi
leaq -0x48(%rbp), %rdi
callq 0x4de80
jmp 0x70279
leaq -0x30(%rbp), %rdi
leaq -0x48(%rbp), %rsi
callq 0x5f1d0
jmp 0x70288
leaq -0x30(%rbp), %rdi
callq 0x5fc10
movq %rax, -0x340(%rbp)
jmp 0x7029a
movq -0x340(%rbp), %rdi
callq 0x5f9e0
movq %rax, -0x350(%rbp)
movq $0x0, -0x88(%rbp)
leaq -0x88(%rbp), %rdi
movq %rdi, -0x348(%rbp)
callq 0x5fd20
movq -0x330(%rbp), %rdi
movq -0x350(%rbp), %rsi
movq -0x348(%rbp), %rdx
callq 0x848a0
jmp 0x702e7
leaq -0x88(%rbp), %rdi
callq 0x5fd60
leaq -0x30(%rbp), %rdi
callq 0x300e0
leaq -0x48(%rbp), %rdi
callq 0x4dee0
leaq -0x58(%rbp), %rdi
callq 0x13080
leaq -0x68(%rbp), %rdi
callq 0x12f40
movl $0x2a, -0xfc(%rbp)
leaq -0xf8(%rbp), %rdi
leaq -0xfc(%rbp), %rsi
callq 0x67db0
jmp 0x70336
leaq -0xe8(%rbp), %rdi
leaq -0xf8(%rbp), %rsi
callq 0x12f60
movl $0x20, -0x124(%rbp)
leaq -0x120(%rbp), %rdi
leaq -0x124(%rbp), %rsi
callq 0x67db0
jmp 0x70368
leaq -0x110(%rbp), %rdi
movq %rdi, -0x358(%rbp)
leaq -0x120(%rbp), %rsi
callq 0x12f60
movq -0x358(%rbp), %rdx
leaq -0xd8(%rbp), %rdi
leaq -0xe8(%rbp), %rsi
callq 0x53720
jmp 0x7039e
leaq -0xb0(%rbp), %rdi
leaq -0xd8(%rbp), %rsi
callq 0x5f1d0
jmp 0x703b3
leaq -0xb0(%rbp), %rdi
callq 0x5fc10
movq %rax, -0x360(%rbp)
jmp 0x703c8
movq -0x360(%rbp), %rdi
callq 0x5f9e0
movq %rax, -0x370(%rbp)
movq $0x0, -0x130(%rbp)
leaq -0x130(%rbp), %rdi
movq %rdi, -0x368(%rbp)
callq 0x5fd20
movq -0x330(%rbp), %rdi
movq -0x370(%rbp), %rsi
movq -0x368(%rbp), %rdx
callq 0x848a0
jmp 0x70415
leaq -0x130(%rbp), %rdi
callq 0x5fd60
leaq -0xb0(%rbp), %rdi
callq 0x300e0
leaq -0xd8(%rbp), %rdi
callq 0x53770
leaq -0x110(%rbp), %rdi
callq 0x13080
leaq -0x120(%rbp), %rdi
callq 0x12f90
leaq -0xe8(%rbp), %rdi
callq 0x13080
leaq -0xf8(%rbp), %rdi
callq 0x12f90
movl $0x20, -0x1a4(%rbp)
leaq -0x1a0(%rbp), %rdi
leaq -0x1a4(%rbp), %rsi
callq 0x67db0
jmp 0x70488
leaq -0x190(%rbp), %rdi
leaq -0x1a0(%rbp), %rsi
callq 0x12f60
movl $0xc, -0x1cc(%rbp)
leaq -0x1c8(%rbp), %rdi
leaq -0x1cc(%rbp), %rsi
callq 0x67db0
jmp 0x704ba
leaq -0x1b8(%rbp), %rdi
movq %rdi, -0x378(%rbp)
leaq -0x1c8(%rbp), %rsi
callq 0x12f60
movq -0x378(%rbp), %rdx
leaq -0x180(%rbp), %rdi
leaq -0x190(%rbp), %rsi
callq 0x54da0
jmp 0x704f0
leaq -0x158(%rbp), %rdi
leaq -0x180(%rbp), %rsi
callq 0x5f1d0
jmp 0x70505
leaq -0x158(%rbp), %rdi
callq 0x5fc10
movq %rax, -0x380(%rbp)
jmp 0x7051a
movq -0x380(%rbp), %rdi
callq 0x5f9e0
movq %rax, -0x390(%rbp)
movq $0x0, -0x1d8(%rbp)
leaq -0x1d8(%rbp), %rdi
movq %rdi, -0x388(%rbp)
callq 0x5fd20
movq -0x330(%rbp), %rdi
movq -0x390(%rbp), %rsi
movq -0x388(%rbp), %rdx
callq 0x848a0
jmp 0x70567
leaq -0x1d8(%rbp), %rdi
callq 0x5fd60
leaq -0x158(%rbp), %rdi
callq 0x300e0
leaq -0x180(%rbp), %rdi
callq 0x54df0
leaq -0x1b8(%rbp), %rdi
callq 0x13080
leaq -0x1c8(%rbp), %rdi
callq 0x12f90
leaq -0x190(%rbp), %rdi
callq 0x13080
leaq -0x1a0(%rbp), %rdi
callq 0x12f90
movb $0x1, -0x249(%rbp)
leaq -0x248(%rbp), %rdi
leaq -0x249(%rbp), %rsi
callq 0x67fd0
jmp 0x705d7
leaq -0x238(%rbp), %rdi
leaq -0x248(%rbp), %rsi
callq 0x12f10
movb $0x0, -0x271(%rbp)
leaq -0x270(%rbp), %rdi
leaq -0x271(%rbp), %rsi
callq 0x67fd0
jmp 0x70606
leaq -0x260(%rbp), %rdi
movq %rdi, -0x398(%rbp)
leaq -0x270(%rbp), %rsi
callq 0x12f10
movq -0x398(%rbp), %rdx
leaq -0x228(%rbp), %rdi
leaq -0x238(%rbp), %rsi
callq 0x56420
jmp 0x7063c
leaq -0x200(%rbp), %rdi
leaq -0x228(%rbp), %rsi
callq 0x5f1d0
jmp 0x70651
leaq -0x200(%rbp), %rdi
callq 0x5fc10
movq %rax, -0x3a0(%rbp)
jmp 0x70666
movq -0x3a0(%rbp), %rdi
callq 0x5f9e0
movq %rax, -0x3b0(%rbp)
movq $0x0, -0x280(%rbp)
leaq -0x280(%rbp), %rdi
movq %rdi, -0x3a8(%rbp)
callq 0x5fd20
movq -0x330(%rbp), %rdi
movq -0x3b0(%rbp), %rsi
movq -0x3a8(%rbp), %rdx
callq 0x848a0
jmp 0x706b3
leaq -0x280(%rbp), %rdi
callq 0x5fd60
leaq -0x200(%rbp), %rdi
callq 0x300e0
leaq -0x228(%rbp), %rdi
callq 0x56470
leaq -0x260(%rbp), %rdi
callq 0x13080
leaq -0x270(%rbp), %rdi
callq 0x12f40
leaq -0x238(%rbp), %rdi
callq 0x13080
leaq -0x248(%rbp), %rdi
callq 0x12f40
movb $0x1, -0x2f1(%rbp)
leaq -0x2f0(%rbp), %rdi
leaq -0x2f1(%rbp), %rsi
callq 0x67fd0
jmp 0x70723
leaq -0x2e0(%rbp), %rdi
leaq -0x2f0(%rbp), %rsi
callq 0x12f10
movb $0x0, -0x319(%rbp)
leaq -0x318(%rbp), %rdi
leaq -0x319(%rbp), %rsi
callq 0x67fd0
jmp 0x70752
leaq -0x308(%rbp), %rdi
movq %rdi, -0x3b8(%rbp)
leaq -0x318(%rbp), %rsi
callq 0x12f10
movq -0x3b8(%rbp), %rdx
leaq -0x2d0(%rbp), %rdi
leaq -0x2e0(%rbp), %rsi
callq 0x84af0
jmp 0x70788
leaq -0x2a8(%rbp), %rdi
leaq -0x2d0(%rbp), %rsi
callq 0x5f1d0
jmp 0x7079d
leaq -0x2a8(%rbp), %rdi
callq 0x5fc10
movq %rax, -0x3c0(%rbp)
jmp 0x707b2
movq -0x3c0(%rbp), %rdi
callq 0x5f9e0
movq %rax, -0x3d0(%rbp)
movq $0x0, -0x328(%rbp)
leaq -0x328(%rbp), %rdi
movq %rdi, -0x3c8(%rbp)
callq 0x5fd20
movq -0x330(%rbp), %rdi
movq -0x3d0(%rbp), %rsi
movq -0x3c8(%rbp), %rdx
callq 0x848a0
jmp 0x707ff
leaq -0x328(%rbp), %rdi
callq 0x5fd60
leaq -0x2a8(%rbp), %rdi
callq 0x300e0
leaq -0x2d0(%rbp), %rdi
callq 0x84b30
leaq -0x308(%rbp), %rdi
callq 0x13080
leaq -0x318(%rbp), %rdi
callq 0x12f40
leaq -0x2e0(%rbp), %rdi
callq 0x13080
leaq -0x2f0(%rbp), %rdi
callq 0x12f40
addq $0x3d0, %rsp            # imm = 0x3D0
popq %rbp
retq
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x78(%rbp)
movl %eax, -0x7c(%rbp)
jmp 0x70b47
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x78(%rbp)
movl %eax, -0x7c(%rbp)
jmp 0x708c1
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x78(%rbp)
movl %eax, -0x7c(%rbp)
jmp 0x708b8
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x78(%rbp)
movl %eax, -0x7c(%rbp)
jmp 0x708af
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x78(%rbp)
movl %eax, -0x7c(%rbp)
leaq -0x88(%rbp), %rdi
callq 0x5fd60
leaq -0x30(%rbp), %rdi
callq 0x300e0
leaq -0x48(%rbp), %rdi
callq 0x4dee0
leaq -0x58(%rbp), %rdi
callq 0x13080
leaq -0x68(%rbp), %rdi
callq 0x12f40
jmp 0x70b47
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x78(%rbp)
movl %eax, -0x7c(%rbp)
jmp 0x70958
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x78(%rbp)
movl %eax, -0x7c(%rbp)
jmp 0x70940
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x78(%rbp)
movl %eax, -0x7c(%rbp)
jmp 0x70934
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x78(%rbp)
movl %eax, -0x7c(%rbp)
jmp 0x70928
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x78(%rbp)
movl %eax, -0x7c(%rbp)
leaq -0x130(%rbp), %rdi
callq 0x5fd60
leaq -0xb0(%rbp), %rdi
callq 0x300e0
leaq -0xd8(%rbp), %rdi
callq 0x53770
leaq -0x110(%rbp), %rdi
callq 0x13080
leaq -0x120(%rbp), %rdi
callq 0x12f90
leaq -0xe8(%rbp), %rdi
callq 0x13080
leaq -0xf8(%rbp), %rdi
callq 0x12f90
jmp 0x70b47
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x78(%rbp)
movl %eax, -0x7c(%rbp)
jmp 0x709f5
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x78(%rbp)
movl %eax, -0x7c(%rbp)
jmp 0x709dd
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x78(%rbp)
movl %eax, -0x7c(%rbp)
jmp 0x709d1
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x78(%rbp)
movl %eax, -0x7c(%rbp)
jmp 0x709c5
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x78(%rbp)
movl %eax, -0x7c(%rbp)
leaq -0x1d8(%rbp), %rdi
callq 0x5fd60
leaq -0x158(%rbp), %rdi
callq 0x300e0
leaq -0x180(%rbp), %rdi
callq 0x54df0
leaq -0x1b8(%rbp), %rdi
callq 0x13080
leaq -0x1c8(%rbp), %rdi
callq 0x12f90
leaq -0x190(%rbp), %rdi
callq 0x13080
leaq -0x1a0(%rbp), %rdi
callq 0x12f90
jmp 0x70b47
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x78(%rbp)
movl %eax, -0x7c(%rbp)
jmp 0x70a92
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x78(%rbp)
movl %eax, -0x7c(%rbp)
jmp 0x70a7a
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x78(%rbp)
movl %eax, -0x7c(%rbp)
jmp 0x70a6e
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x78(%rbp)
movl %eax, -0x7c(%rbp)
jmp 0x70a62
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x78(%rbp)
movl %eax, -0x7c(%rbp)
leaq -0x280(%rbp), %rdi
callq 0x5fd60
leaq -0x200(%rbp), %rdi
callq 0x300e0
leaq -0x228(%rbp), %rdi
callq 0x56470
leaq -0x260(%rbp), %rdi
callq 0x13080
leaq -0x270(%rbp), %rdi
callq 0x12f40
leaq -0x238(%rbp), %rdi
callq 0x13080
leaq -0x248(%rbp), %rdi
callq 0x12f40
jmp 0x70b47
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x78(%rbp)
movl %eax, -0x7c(%rbp)
jmp 0x70b2f
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x78(%rbp)
movl %eax, -0x7c(%rbp)
jmp 0x70b17
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x78(%rbp)
movl %eax, -0x7c(%rbp)
jmp 0x70b0b
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x78(%rbp)
movl %eax, -0x7c(%rbp)
jmp 0x70aff
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x78(%rbp)
movl %eax, -0x7c(%rbp)
leaq -0x328(%rbp), %rdi
callq 0x5fd60
leaq -0x2a8(%rbp), %rdi
callq 0x300e0
leaq -0x2d0(%rbp), %rdi
callq 0x84b30
leaq -0x308(%rbp), %rdi
callq 0x13080
leaq -0x318(%rbp), %rdi
callq 0x12f40
leaq -0x2e0(%rbp), %rdi
callq 0x13080
leaq -0x2f0(%rbp), %rdi
callq 0x12f40
movq -0x330(%rbp), %rdi
callq 0x71f80
movq -0x78(%rbp), %rdi
callq 0xa650
nopl (%rax)