// File: /workspace/github_cpp_makefile_star2_O3/halfflat[P]tinyopt/test/test_sink.cc
// Function: sink_optionalrefctor_Test::TestBody()
TEST(sink, optionalrefctor) {
    std::optional<int> oa;
    to::sink soa(oa);

    ASSERT_FALSE(oa);
    EXPECT_FALSE(soa("foo"));
    EXPECT_FALSE(oa);

    EXPECT_TRUE(soa("312"));
    EXPECT_TRUE(oa);
    EXPECT_EQ(*oa, 312);
}

// Assembly:
pushq %r14
pushq %rbx
subq $0x68, %rsp
leaq 0x40(%rsp), %rax
movb $0x0, 0x4(%rax)
leaq 0x50(%rsp), %rsi
movq $0x0, (%rsi)
movq %rax, -0x8(%rsi)
leaq 0x2e19(%rip), %rax      # 0x1599c
movq %rax, 0x10(%rsi)
leaq 0x2e46(%rip), %rax      # 0x159d4
movq %rax, 0x8(%rsi)
leaq 0x59569(%rip), %rdx     # 0x6c102
leaq 0x20(%rsp), %rdi
callq 0x1567a
cmpb $0x0, 0x20(%rsp)
je 0x12c6f
movl 0x24(%rsp), %eax
movq 0x48(%rsp), %rcx
btsq $0x20, %rax
movq %rax, (%rcx)
leaq 0x18(%rsp), %r14
movb $0x0, -0x8(%r14)
movq $0x0, (%r14)
movq %rsp, %rdi
callq 0x4ca86
leaq 0x59577(%rip), %rdx     # 0x6c156
leaq 0x59526(%rip), %rcx     # 0x6c10c
leaq 0x59519(%rip), %r8      # 0x6c106
leaq 0x20(%rsp), %rdi
leaq 0x10(%rsp), %rsi
callq 0x46893
movq 0x20(%rsp), %r8
leaq 0x594ad(%rip), %rdx     # 0x6c0b5
leaq 0x8(%rsp), %rdi
movl $0x1, %esi
movl $0x30, %ecx
callq 0x4902a
leaq 0x8(%rsp), %rdi
movq %rsp, %rsi
callq 0x46a1c
leaq 0x8(%rsp), %rdi
callq 0x49096
leaq 0x30(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x12c4e
movq 0x30(%rsp), %rsi
incq %rsi
callq 0xd530
movq (%rsp), %rdi
testq %rdi, %rdi
je 0x12c5d
movq (%rdi), %rax
callq *0x8(%rax)
movq 0x18(%rsp), %rsi
testq %rsi, %rsi
je 0x12c6f
movq %r14, %rdi
callq 0x153ca
movb 0x44(%rsp), %al
movl %eax, %ecx
xorb $0x1, %cl
movb %cl, 0x10(%rsp)
movq $0x0, 0x18(%rsp)
testb %al, %al
je 0x12d31
leaq 0x18(%rsp), %r14
movq %rsp, %rdi
callq 0x4ca86
leaq 0x594cc(%rip), %rdx     # 0x6c16d
leaq 0x59464(%rip), %rcx     # 0x6c10c
leaq 0x59457(%rip), %r8      # 0x6c106
leaq 0x20(%rsp), %rdi
leaq 0x10(%rsp), %rsi
callq 0x46893
movq 0x20(%rsp), %r8
leaq 0x593eb(%rip), %rdx     # 0x6c0b5
leaq 0x8(%rsp), %rdi
movl $0x1, %esi
movl $0x31, %ecx
callq 0x4902a
leaq 0x8(%rsp), %rdi
movq %rsp, %rsi
callq 0x46a1c
leaq 0x8(%rsp), %rdi
callq 0x49096
leaq 0x30(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x12d10
movq 0x30(%rsp), %rsi
incq %rsi
callq 0xd530
movq (%rsp), %rdi
testq %rdi, %rdi
je 0x12d1f
movq (%rdi), %rax
callq *0x8(%rax)
movq 0x18(%rsp), %rsi
testq %rsi, %rsi
je 0x12d31
movq %r14, %rdi
callq 0x153ca
leaq 0x593d9(%rip), %rax     # 0x6c111
movq %rax, 0x20(%rsp)
cmpq $0x0, 0x58(%rsp)
je 0x12f8f
leaq 0x48(%rsp), %rdi
leaq 0x20(%rsp), %rsi
callq *0x18(%rdi)
movb %al, 0x10(%rsp)
movq $0x0, 0x18(%rsp)
testb %al, %al
jne 0x12e0f
leaq 0x18(%rsp), %r14
movq %rsp, %rdi
callq 0x4ca86
leaq 0x593e2(%rip), %rdx     # 0x6c161
leaq 0x59380(%rip), %rcx     # 0x6c106
leaq 0x5937f(%rip), %r8      # 0x6c10c
leaq 0x20(%rsp), %rdi
leaq 0x10(%rsp), %rsi
callq 0x46893
movq 0x20(%rsp), %r8
leaq 0x5930d(%rip), %rdx     # 0x6c0b5
leaq 0x8(%rsp), %rdi
movl $0x1, %esi
movl $0x33, %ecx
callq 0x4902a
leaq 0x8(%rsp), %rdi
movq %rsp, %rsi
callq 0x46a1c
leaq 0x8(%rsp), %rdi
callq 0x49096
leaq 0x30(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x12dee
movq 0x30(%rsp), %rsi
incq %rsi
callq 0xd530
movq (%rsp), %rdi
testq %rdi, %rdi
je 0x12dfd
movq (%rdi), %rax
callq *0x8(%rax)
movq 0x18(%rsp), %rsi
testq %rsi, %rsi
je 0x12e0f
movq %r14, %rdi
callq 0x153ca
movb 0x44(%rsp), %al
movb %al, 0x10(%rsp)
movq $0x0, 0x18(%rsp)
testb %al, %al
jne 0x12ecc
leaq 0x18(%rsp), %r14
movq %rsp, %rdi
callq 0x4ca86
leaq 0x59331(%rip), %rdx     # 0x6c16d
leaq 0x592c3(%rip), %rcx     # 0x6c106
leaq 0x592c2(%rip), %r8      # 0x6c10c
leaq 0x20(%rsp), %rdi
leaq 0x10(%rsp), %rsi
callq 0x46893
movq 0x20(%rsp), %r8
leaq 0x59250(%rip), %rdx     # 0x6c0b5
leaq 0x8(%rsp), %rdi
movl $0x1, %esi
movl $0x34, %ecx
callq 0x4902a
leaq 0x8(%rsp), %rdi
movq %rsp, %rsi
callq 0x46a1c
leaq 0x8(%rsp), %rdi
callq 0x49096
leaq 0x30(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x12eab
movq 0x30(%rsp), %rsi
incq %rsi
callq 0xd530
movq (%rsp), %rdi
testq %rdi, %rdi
je 0x12eba
movq (%rdi), %rax
callq *0x8(%rax)
movq 0x18(%rsp), %rsi
testq %rsi, %rsi
je 0x12ecc
movq %r14, %rdi
callq 0x153ca
leaq 0x10(%rsp), %r8
movl $0x138, (%r8)           # imm = 0x138
leaq 0x5928d(%rip), %rsi     # 0x6c16c
leaq 0x5922b(%rip), %rdx     # 0x6c111
leaq 0x20(%rsp), %rdi
leaq 0x40(%rsp), %rcx
callq 0x157b7
cmpb $0x0, 0x20(%rsp)
jne 0x12f5a
leaq 0x10(%rsp), %rdi
callq 0x4ca86
movq 0x28(%rsp), %rax
testq %rax, %rax
je 0x12f15
movq (%rax), %r8
jmp 0x12f1c
leaq 0x5c0b9(%rip), %r8      # 0x6efd5
leaq 0x59192(%rip), %rdx     # 0x6c0b5
movq %rsp, %rdi
movl $0x1, %esi
movl $0x35, %ecx
callq 0x4902a
movq %rsp, %rdi
leaq 0x10(%rsp), %rsi
callq 0x46a1c
movq %rsp, %rdi
callq 0x49096
movq 0x10(%rsp), %rdi
testq %rdi, %rdi
je 0x12f5a
movq (%rdi), %rax
callq *0x8(%rax)
movq 0x28(%rsp), %rsi
testq %rsi, %rsi
je 0x12f6e
leaq 0x28(%rsp), %rdi
callq 0x153ca
movq 0x58(%rsp), %rax
testq %rax, %rax
je 0x12f87
leaq 0x48(%rsp), %rdi
movq %rdi, %rsi
movl $0x3, %edx
callq *%rax
addq $0x68, %rsp
popq %rbx
popq %r14
retq
callq 0xd1f0
movq %rax, %rbx
movq %rsp, %rdi
callq 0x49096
jmp 0x12fa4
movq %rax, %rbx
movq 0x10(%rsp), %rdi
testq %rdi, %rdi
je 0x12fb9
movq (%rdi), %rax
callq *0x8(%rax)
jmp 0x12fb9
movq %rax, %rbx
movq 0x28(%rsp), %rsi
testq %rsi, %rsi
je 0x13049
leaq 0x28(%rsp), %rdi
jmp 0x13039
jmp 0x12fe4
jmp 0x12ff5
jmp 0x13015
jmp 0x12fe4
jmp 0x13029
jmp 0x12ff5
jmp 0x13015
jmp 0x13029
jmp 0x12fe4
jmp 0x12ff5
jmp 0x13015
movq %rax, %rbx
leaq 0x8(%rsp), %rdi
callq 0x49096
jmp 0x12ff8
jmp 0x13029
movq %rax, %rbx
leaq 0x30(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x13018
movq 0x30(%rsp), %rsi
incq %rsi
callq 0xd530
jmp 0x13018
movq %rax, %rbx
movq (%rsp), %rdi
testq %rdi, %rdi
je 0x1302c
movq (%rdi), %rax
callq *0x8(%rax)
jmp 0x1302c
movq %rax, %rbx
movq 0x18(%rsp), %rsi
testq %rsi, %rsi
je 0x13049
movq %r14, %rdi
callq 0x153ca
jmp 0x13049
jmp 0x1306a
jmp 0x13046
jmp 0x13046
movq %rax, %rbx
movq 0x58(%rsp), %rax
testq %rax, %rax
je 0x13062
leaq 0x48(%rsp), %rdi
movq %rdi, %rsi
movl $0x3, %edx
callq *%rax
movq %rbx, %rdi
callq 0xda70
movq %rax, %rdi
callq 0x1536f