// File: /workspace/github_cpp_makefile_star2_O1/halfflat[P]tinyopt/test/test_maybe.cc
// Function: maybe_conditional_assign_Test::TestBody()
TEST(maybe, conditional_assign) {
    int r = 0;

    EXPECT_TRUE(r << maybe<int>(0));
    EXPECT_EQ(0, r);

    EXPECT_TRUE(r << maybe<int>(4));
    EXPECT_EQ(4, r);

    EXPECT_TRUE(r << maybe<double>(5.3));
    EXPECT_EQ(5, r);

    EXPECT_FALSE(r << maybe<int>());
    EXPECT_EQ(5, r);
}

// Assembly:
pushq %rbx
subq $0x30, %rsp
xorl %eax, %eax
leaq 0x2c(%rsp), %r8
movl %eax, (%r8)
leaq 0x8(%rsp), %rcx
movl %eax, (%rcx)
leaq 0x5dddf(%rip), %rsi     # 0x74cf8
leaq 0x594b4(%rip), %rdx     # 0x703d4
leaq 0x18(%rsp), %rbx
movq %rbx, %rdi
callq 0x15aba
cmpb $0x0, (%rbx)
jne 0x16f96
leaq 0x8(%rsp), %rdi
callq 0x4e2e8
movq 0x20(%rsp), %rax
testq %rax, %rax
je 0x16f4b
movq (%rax), %r8
jmp 0x16f52
leaq 0x5a0a6(%rip), %r8      # 0x70ff8
leaq 0x57b46(%rip), %rdx     # 0x6ea9f
leaq 0x10(%rsp), %rdi
movl $0x1, %esi
movl $0x4a, %ecx
callq 0x4a84c
leaq 0x10(%rsp), %rdi
leaq 0x8(%rsp), %rsi
callq 0x481aa
leaq 0x10(%rsp), %rdi
callq 0x4a8b8
movq 0x8(%rsp), %rdi
testq %rdi, %rdi
je 0x16f96
movq (%rdi), %rax
callq *0x8(%rax)
movq 0x20(%rsp), %rsi
testq %rsi, %rsi
je 0x16faa
leaq 0x20(%rsp), %rdi
callq 0x156d0
movl $0x4, %eax
leaq 0x2c(%rsp), %r8
movl %eax, (%r8)
leaq 0x8(%rsp), %rcx
movl %eax, (%rcx)
leaq 0x59a9e(%rip), %rsi     # 0x70a63
leaq 0x59408(%rip), %rdx     # 0x703d4
leaq 0x18(%rsp), %rbx
movq %rbx, %rdi
callq 0x15aba
cmpb $0x0, (%rbx)
jne 0x17042
leaq 0x8(%rsp), %rdi
callq 0x4e2e8
movq 0x20(%rsp), %rax
testq %rax, %rax
je 0x16ff7
movq (%rax), %r8
jmp 0x16ffe
leaq 0x59ffa(%rip), %r8      # 0x70ff8
leaq 0x57a9a(%rip), %rdx     # 0x6ea9f
leaq 0x10(%rsp), %rdi
movl $0x1, %esi
movl $0x4d, %ecx
callq 0x4a84c
leaq 0x10(%rsp), %rdi
leaq 0x8(%rsp), %rsi
callq 0x481aa
leaq 0x10(%rsp), %rdi
callq 0x4a8b8
movq 0x8(%rsp), %rdi
testq %rdi, %rdi
je 0x17042
movq (%rdi), %rax
callq *0x8(%rax)
movq 0x20(%rsp), %rsi
testq %rsi, %rsi
je 0x17056
leaq 0x20(%rsp), %rdi
callq 0x156d0
movl $0x5, %eax
leaq 0x2c(%rsp), %r8
movl %eax, (%r8)
leaq 0x8(%rsp), %rcx
movl %eax, (%rcx)
leaq 0x57af7(%rip), %rsi     # 0x6eb68
leaq 0x5935c(%rip), %rdx     # 0x703d4
leaq 0x18(%rsp), %rbx
movq %rbx, %rdi
callq 0x15aba
cmpb $0x0, (%rbx)
jne 0x170ee
leaq 0x8(%rsp), %rdi
callq 0x4e2e8
movq 0x20(%rsp), %rax
testq %rax, %rax
je 0x170a3
movq (%rax), %r8
jmp 0x170aa
leaq 0x59f4e(%rip), %r8      # 0x70ff8
leaq 0x579ee(%rip), %rdx     # 0x6ea9f
leaq 0x10(%rsp), %rdi
movl $0x1, %esi
movl $0x50, %ecx
callq 0x4a84c
leaq 0x10(%rsp), %rdi
leaq 0x8(%rsp), %rsi
callq 0x481aa
leaq 0x10(%rsp), %rdi
callq 0x4a8b8
movq 0x8(%rsp), %rdi
testq %rdi, %rdi
je 0x170ee
movq (%rdi), %rax
callq *0x8(%rax)
movq 0x20(%rsp), %rsi
testq %rsi, %rsi
je 0x17102
leaq 0x20(%rsp), %rdi
callq 0x156d0
leaq 0x8(%rsp), %rcx
movl $0x5, (%rcx)
leaq 0x57a54(%rip), %rsi     # 0x6eb68
leaq 0x592b9(%rip), %rdx     # 0x703d4
leaq 0x18(%rsp), %rbx
leaq 0x2c(%rsp), %r8
movq %rbx, %rdi
callq 0x15aba
cmpb $0x0, (%rbx)
jne 0x17196
leaq 0x8(%rsp), %rdi
callq 0x4e2e8
movq 0x20(%rsp), %rax
testq %rax, %rax
je 0x1714b
movq (%rax), %r8
jmp 0x17152
leaq 0x59ea6(%rip), %r8      # 0x70ff8
leaq 0x57946(%rip), %rdx     # 0x6ea9f
leaq 0x10(%rsp), %rdi
movl $0x1, %esi
movl $0x53, %ecx
callq 0x4a84c
leaq 0x10(%rsp), %rdi
leaq 0x8(%rsp), %rsi
callq 0x481aa
leaq 0x10(%rsp), %rdi
callq 0x4a8b8
movq 0x8(%rsp), %rdi
testq %rdi, %rdi
je 0x17196
movq (%rdi), %rax
callq *0x8(%rax)
movq 0x20(%rsp), %rsi
testq %rsi, %rsi
je 0x171aa
leaq 0x20(%rsp), %rdi
callq 0x156d0
addq $0x30, %rsp
popq %rbx
retq
jmp 0x171c0
jmp 0x171d1
jmp 0x171c0
jmp 0x171ef
jmp 0x171d1
jmp 0x171c0
jmp 0x171ef
jmp 0x171d1
movq %rax, %rbx
leaq 0x10(%rsp), %rdi
callq 0x4a8b8
jmp 0x171d4
jmp 0x171ef
movq %rax, %rbx
movq 0x8(%rsp), %rdi
testq %rdi, %rdi
je 0x171e4
movq (%rdi), %rax
callq *0x8(%rax)
movq $0x0, 0x8(%rsp)
jmp 0x171f2
movq %rax, %rbx
movq 0x20(%rsp), %rsi
testq %rsi, %rsi
je 0x17206
leaq 0x20(%rsp), %rdi
callq 0x156d0
movq %rbx, %rdi
callq 0xda70