// File: /workspace/github_cpp_makefile_star2_O2/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 0x48(%rsp), %rbx
andq $0x0, 0x8(%rbx)
leaq 0x40(%rsp), %rax
movb $0x0, 0x4(%rax)
movq %rax, (%rbx)
leaq 0x2758(%rip), %rax      # 0x13c08
movq %rax, 0x18(%rbx)
leaq 0x2753(%rip), %rax      # 0x13c0e
movq %rax, 0x10(%rbx)
leaq 0x28(%rsp), %rdi
movb $0x1, -0x8(%rdi)
andq $0x0, (%rdi)
callq 0x13646
leaq 0x44c2a(%rip), %rsi     # 0x56102
movq %rbx, %rdi
callq 0x1362c
movl %eax, %ecx
xorb $0x1, %cl
leaq 0x18(%rsp), %r14
movb %cl, -0x8(%r14)
andq $0x0, (%r14)
testb %al, %al
je 0x1156e
movq %rsp, %rdi
callq 0x3d5f6
leaq 0x44c64(%rip), %rdx     # 0x56169
leaq 0x44c09(%rip), %rcx     # 0x56115
leaq 0x44bfc(%rip), %r8      # 0x5610f
leaq 0x20(%rsp), %rdi
leaq 0x10(%rsp), %rsi
callq 0x399e5
movq 0x20(%rsp), %r8
leaq 0x44b87(%rip), %rdx     # 0x560b5
leaq 0x8(%rsp), %rdi
pushq $0x1
popq %rsi
pushq $0x30
popq %rcx
callq 0x3b5b6
leaq 0x8(%rsp), %rdi
movq %rsp, %rsi
callq 0x39b08
leaq 0x8(%rsp), %rdi
callq 0x3b616
leaq 0x20(%rsp), %rdi
callq 0xdbe8
movq (%rsp), %rdi
testq %rdi, %rdi
je 0x1156e
movq (%rdi), %rax
callq *0x8(%rax)
movq %r14, %rdi
callq 0x13646
movb 0x44(%rsp), %al
movl %eax, %ecx
xorb $0x1, %cl
leaq 0x18(%rsp), %r14
movb %cl, -0x8(%r14)
andq $0x0, (%r14)
testb %al, %al
je 0x11608
movq %rsp, %rdi
callq 0x3d5f6
leaq 0x44be1(%rip), %rdx     # 0x56180
leaq 0x44b6f(%rip), %rcx     # 0x56115
leaq 0x44b62(%rip), %r8      # 0x5610f
leaq 0x20(%rsp), %rdi
leaq 0x10(%rsp), %rsi
callq 0x399e5
movq 0x20(%rsp), %r8
leaq 0x44aed(%rip), %rdx     # 0x560b5
leaq 0x8(%rsp), %rdi
pushq $0x1
popq %rsi
pushq $0x31
popq %rcx
callq 0x3b5b6
leaq 0x8(%rsp), %rdi
movq %rsp, %rsi
callq 0x39b08
leaq 0x8(%rsp), %rdi
callq 0x3b616
leaq 0x20(%rsp), %rdi
callq 0xdbe8
movq (%rsp), %rdi
testq %rdi, %rdi
je 0x11608
movq (%rdi), %rax
callq *0x8(%rax)
movq %r14, %rdi
callq 0x13646
leaq 0x44b03(%rip), %rsi     # 0x5611a
leaq 0x48(%rsp), %rdi
callq 0x1362c
leaq 0x18(%rsp), %r14
movb %al, -0x8(%r14)
andq $0x0, (%r14)
testb %al, %al
jne 0x116aa
movq %rsp, %rdi
callq 0x3d5f6
leaq 0x44b33(%rip), %rdx     # 0x56174
leaq 0x44ac7(%rip), %rcx     # 0x5610f
leaq 0x44ac6(%rip), %r8      # 0x56115
leaq 0x20(%rsp), %rdi
leaq 0x10(%rsp), %rsi
callq 0x399e5
movq 0x20(%rsp), %r8
leaq 0x44a4b(%rip), %rdx     # 0x560b5
leaq 0x8(%rsp), %rdi
pushq $0x1
popq %rsi
pushq $0x33
popq %rcx
callq 0x3b5b6
leaq 0x8(%rsp), %rdi
movq %rsp, %rsi
callq 0x39b08
leaq 0x8(%rsp), %rdi
callq 0x3b616
leaq 0x20(%rsp), %rdi
callq 0xdbe8
movq (%rsp), %rdi
testq %rdi, %rdi
je 0x116aa
movq (%rdi), %rax
callq *0x8(%rax)
movq %r14, %rdi
callq 0x13646
movb 0x44(%rsp), %al
leaq 0x18(%rsp), %r14
movb %al, -0x8(%r14)
andq $0x0, (%r14)
testb %al, %al
jne 0x1173f
movq %rsp, %rdi
callq 0x3d5f6
leaq 0x44aaa(%rip), %rdx     # 0x56180
leaq 0x44a32(%rip), %rcx     # 0x5610f
leaq 0x44a31(%rip), %r8      # 0x56115
leaq 0x20(%rsp), %rdi
leaq 0x10(%rsp), %rsi
callq 0x399e5
movq 0x20(%rsp), %r8
leaq 0x449b6(%rip), %rdx     # 0x560b5
leaq 0x8(%rsp), %rdi
pushq $0x1
popq %rsi
pushq $0x34
popq %rcx
callq 0x3b5b6
leaq 0x8(%rsp), %rdi
movq %rsp, %rsi
callq 0x39b08
leaq 0x8(%rsp), %rdi
callq 0x3b616
leaq 0x20(%rsp), %rdi
callq 0xdbe8
movq (%rsp), %rdi
testq %rdi, %rdi
je 0x1173f
movq (%rdi), %rax
callq *0x8(%rax)
movq %r14, %rdi
callq 0x13646
leaq 0x10(%rsp), %r8
movl $0x138, (%r8)           # imm = 0x138
leaq 0x44a25(%rip), %rsi     # 0x5617f
leaq 0x449b9(%rip), %rdx     # 0x5611a
leaq 0x20(%rsp), %rdi
leaq 0x40(%rsp), %rcx
callq 0x13a52
cmpb $0x0, 0x20(%rsp)
jne 0x117d1
leaq 0x10(%rsp), %rdi
callq 0x3d5f6
movq 0x28(%rsp), %rax
testq %rax, %rax
je 0x11790
movq (%rax), %r8
jmp 0x11797
leaq 0x478d3(%rip), %r8      # 0x5906a
leaq 0x44917(%rip), %rdx     # 0x560b5
movq %rsp, %rdi
pushq $0x1
popq %rsi
pushq $0x35
popq %rcx
callq 0x3b5b6
movq %rsp, %rdi
leaq 0x10(%rsp), %rsi
callq 0x39b08
movq %rsp, %rdi
callq 0x3b616
movq 0x10(%rsp), %rdi
testq %rdi, %rdi
je 0x117d1
movq (%rdi), %rax
callq *0x8(%rax)
leaq 0x28(%rsp), %rdi
callq 0x13646
leaq 0x48(%rsp), %rdi
callq 0x1367e
addq $0x68, %rsp
popq %rbx
popq %r14
retq
movq %rax, %rbx
movq %rsp, %rdi
callq 0x3b616
jmp 0x117fd
movq %rax, %rbx
movq 0x10(%rsp), %rdi
testq %rdi, %rdi
je 0x11812
movq (%rdi), %rax
callq *0x8(%rax)
jmp 0x11812
movq %rax, %rbx
leaq 0x28(%rsp), %rdi
jmp 0x11869
jmp 0x1182f
jmp 0x11840
jmp 0x1184f
jmp 0x1182f
jmp 0x11863
jmp 0x11840
jmp 0x1184f
jmp 0x11863
jmp 0x1182f
jmp 0x11840
jmp 0x1184f
movq %rax, %rbx
leaq 0x8(%rsp), %rdi
callq 0x3b616
jmp 0x11843
jmp 0x11863
movq %rax, %rbx
leaq 0x20(%rsp), %rdi
callq 0xdbe8
jmp 0x11852
movq %rax, %rbx
movq (%rsp), %rdi
testq %rdi, %rdi
je 0x11866
movq (%rdi), %rax
callq *0x8(%rax)
jmp 0x11866
movq %rax, %rbx
movq %r14, %rdi
callq 0x13646
jmp 0x11877
jmp 0x11874
jmp 0x11874
movq %rax, %rbx
leaq 0x48(%rsp), %rdi
callq 0x1367e
movq %rbx, %rdi
callq 0xdaa0
nop