// File: /workspace/github_cpp_makefile_star2_O2/halfflat[P]tinyopt/test/test_sink.cc
// Function: sink_action_implicit_Test::TestBody()
TEST(sink, action_implicit) {
    int n = 0;
    auto setter = [&n](int y) { n = y; };

    auto a = to::action(setter);
    EXPECT_TRUE(a("17"));
    EXPECT_EQ(17, n);

    EXPECT_FALSE(a("fishsticks"));
    EXPECT_EQ(17, n);

    int y = 0;
    auto voidsetter = [&y]() { ++y; };

    auto b = to::action(voidsetter);
    EXPECT_TRUE(b(nullptr));
    EXPECT_EQ(1, y);
    EXPECT_TRUE(b("wizard"));
    EXPECT_EQ(2, y);
}

// Assembly:
pushq %r14
pushq %rbx
subq $0x88, %rsp
leaq 0x44(%rsp), %rax
andl $0x0, (%rax)
leaq 0x68(%rsp), %rdi
andq $0x0, 0x8(%rdi)
movq %rax, (%rdi)
leaq 0x168a(%rip), %rax      # 0x13288
movq %rax, 0x18(%rdi)
leaq 0x16b7(%rip), %rax      # 0x132c0
movq %rax, 0x10(%rdi)
leaq 0x44528(%rip), %rsi     # 0x5613c
callq 0x1362c
leaq 0x20(%rsp), %r14
movb %al, -0x8(%r14)
andq $0x0, (%r14)
testb %al, %al
jne 0x11ca1
leaq 0x8(%rsp), %rdi
callq 0x3d5f6
leaq 0x44586(%rip), %rdx     # 0x561c1
leaq 0x444cd(%rip), %rcx     # 0x5610f
leaq 0x444cc(%rip), %r8      # 0x56115
leaq 0x48(%rsp), %rdi
leaq 0x18(%rsp), %rsi
callq 0x399e5
movq 0x48(%rsp), %r8
leaq 0x44451(%rip), %rdx     # 0x560b5
movq %rsp, %rdi
pushq $0x1
popq %rsi
pushq $0x4b
popq %rcx
callq 0x3b5b6
movq %rsp, %rdi
leaq 0x8(%rsp), %rsi
callq 0x39b08
movq %rsp, %rdi
callq 0x3b616
leaq 0x48(%rsp), %rdi
callq 0xdbe8
movq 0x8(%rsp), %rdi
testq %rdi, %rdi
je 0x11ca1
movq (%rdi), %rax
callq *0x8(%rax)
movq %r14, %rdi
callq 0x13646
leaq 0x18(%rsp), %rcx
movl $0x11, (%rcx)
leaq 0x44481(%rip), %rsi     # 0x5613c
leaq 0x4a96f(%rip), %rdx     # 0x5c631
leaq 0x48(%rsp), %rdi
leaq 0x44(%rsp), %r8
callq 0x13a52
cmpb $0x0, 0x48(%rsp)
jne 0x11d38
leaq 0x18(%rsp), %rdi
callq 0x3d5f6
movq 0x50(%rsp), %rax
testq %rax, %rax
je 0x11cf1
movq (%rax), %r8
jmp 0x11cf8
leaq 0x47372(%rip), %r8      # 0x5906a
leaq 0x443b6(%rip), %rdx     # 0x560b5
leaq 0x8(%rsp), %rdi
pushq $0x1
popq %rsi
pushq $0x4c
popq %rcx
callq 0x3b5b6
leaq 0x8(%rsp), %rdi
leaq 0x18(%rsp), %rsi
callq 0x39b08
leaq 0x8(%rsp), %rdi
callq 0x3b616
movq 0x18(%rsp), %rdi
testq %rdi, %rdi
je 0x11d38
movq (%rdi), %rax
callq *0x8(%rax)
leaq 0x50(%rsp), %rdi
callq 0x13646
leaq 0x44480(%rip), %rsi     # 0x561c9
leaq 0x68(%rsp), %rdi
callq 0x1362c
movl %eax, %ecx
xorb $0x1, %cl
leaq 0x20(%rsp), %r14
movb %cl, -0x8(%r14)
andq $0x0, (%r14)
testb %al, %al
je 0x11de0
leaq 0x8(%rsp), %rdi
callq 0x3d5f6
leaq 0x4445a(%rip), %rdx     # 0x561d4
leaq 0x44394(%rip), %rcx     # 0x56115
leaq 0x44387(%rip), %r8      # 0x5610f
leaq 0x48(%rsp), %rdi
leaq 0x18(%rsp), %rsi
callq 0x399e5
movq 0x48(%rsp), %r8
leaq 0x44312(%rip), %rdx     # 0x560b5
movq %rsp, %rdi
pushq $0x1
popq %rsi
pushq $0x4e
popq %rcx
callq 0x3b5b6
movq %rsp, %rdi
leaq 0x8(%rsp), %rsi
callq 0x39b08
movq %rsp, %rdi
callq 0x3b616
leaq 0x48(%rsp), %rdi
callq 0xdbe8
movq 0x8(%rsp), %rdi
testq %rdi, %rdi
je 0x11de0
movq (%rdi), %rax
callq *0x8(%rax)
movq %r14, %rdi
callq 0x13646
leaq 0x18(%rsp), %rcx
movl $0x11, (%rcx)
leaq 0x44342(%rip), %rsi     # 0x5613c
leaq 0x4a830(%rip), %rdx     # 0x5c631
leaq 0x48(%rsp), %rdi
leaq 0x44(%rsp), %r8
callq 0x13a52
cmpb $0x0, 0x48(%rsp)
jne 0x11e77
leaq 0x18(%rsp), %rdi
callq 0x3d5f6
movq 0x50(%rsp), %rax
testq %rax, %rax
je 0x11e30
movq (%rax), %r8
jmp 0x11e37
leaq 0x47233(%rip), %r8      # 0x5906a
leaq 0x44277(%rip), %rdx     # 0x560b5
leaq 0x8(%rsp), %rdi
pushq $0x1
popq %rsi
pushq $0x4f
popq %rcx
callq 0x3b5b6
leaq 0x8(%rsp), %rdi
leaq 0x18(%rsp), %rsi
callq 0x39b08
leaq 0x8(%rsp), %rdi
callq 0x3b616
movq 0x18(%rsp), %rdi
testq %rdi, %rdi
je 0x11e77
movq (%rdi), %rax
callq *0x8(%rax)
leaq 0x50(%rsp), %rbx
movq %rbx, %rdi
callq 0x13646
leaq 0x40(%rsp), %rax
andl $0x0, (%rax)
andq $0x0, (%rbx)
movq %rax, -0x8(%rbx)
leaq 0x144b(%rip), %rax      # 0x132e6
movq %rax, 0x10(%rbx)
leaq 0x1448(%rip), %rax      # 0x132ee
movq %rax, 0x8(%rbx)
leaq 0x48(%rsp), %rdi
xorl %esi, %esi
callq 0x1362c
leaq 0x10(%rsp), %r14
movb %al, -0x8(%r14)
andq $0x0, (%r14)
testb %al, %al
jne 0x11f3f
movq %rsp, %rdi
callq 0x3d5f6
leaq 0x4430e(%rip), %rdx     # 0x561e4
leaq 0x44232(%rip), %rcx     # 0x5610f
leaq 0x44231(%rip), %r8      # 0x56115
leaq 0x18(%rsp), %rdi
leaq 0x8(%rsp), %rsi
callq 0x399e5
movq 0x18(%rsp), %r8
leaq 0x441b6(%rip), %rdx     # 0x560b5
leaq 0x38(%rsp), %rdi
pushq $0x1
popq %rsi
pushq $0x55
popq %rcx
callq 0x3b5b6
leaq 0x38(%rsp), %rdi
movq %rsp, %rsi
callq 0x39b08
leaq 0x38(%rsp), %rdi
callq 0x3b616
leaq 0x18(%rsp), %rdi
callq 0xdbe8
movq (%rsp), %rdi
testq %rdi, %rdi
je 0x11f3f
movq (%rdi), %rax
callq *0x8(%rax)
movq %r14, %rdi
callq 0x13646
leaq 0x8(%rsp), %rcx
movl $0x1, (%rcx)
leaq 0x460e6(%rip), %rsi     # 0x5803f
leaq 0x4a013(%rip), %rdx     # 0x5bf73
leaq 0x18(%rsp), %rdi
leaq 0x40(%rsp), %r8
callq 0x13a52
cmpb $0x0, 0x18(%rsp)
jne 0x11fd0
leaq 0x8(%rsp), %rdi
callq 0x3d5f6
movq 0x20(%rsp), %rax
testq %rax, %rax
je 0x11f8f
movq (%rax), %r8
jmp 0x11f96
leaq 0x470d4(%rip), %r8      # 0x5906a
leaq 0x44118(%rip), %rdx     # 0x560b5
movq %rsp, %rdi
pushq $0x1
popq %rsi
pushq $0x56
popq %rcx
callq 0x3b5b6
movq %rsp, %rdi
leaq 0x8(%rsp), %rsi
callq 0x39b08
movq %rsp, %rdi
callq 0x3b616
movq 0x8(%rsp), %rdi
testq %rdi, %rdi
je 0x11fd0
movq (%rdi), %rax
callq *0x8(%rax)
leaq 0x20(%rsp), %rdi
callq 0x13646
leaq 0x4420e(%rip), %rsi     # 0x561ef
leaq 0x48(%rsp), %rdi
callq 0x1362c
leaq 0x10(%rsp), %r14
movb %al, -0x8(%r14)
andq $0x0, (%r14)
testb %al, %al
jne 0x12074
movq %rsp, %rdi
callq 0x3d5f6
leaq 0x441eb(%rip), %rdx     # 0x561f6
leaq 0x440fd(%rip), %rcx     # 0x5610f
leaq 0x440fc(%rip), %r8      # 0x56115
leaq 0x18(%rsp), %rdi
leaq 0x8(%rsp), %rsi
callq 0x399e5
movq 0x18(%rsp), %r8
leaq 0x44081(%rip), %rdx     # 0x560b5
leaq 0x38(%rsp), %rdi
pushq $0x1
popq %rsi
pushq $0x57
popq %rcx
callq 0x3b5b6
leaq 0x38(%rsp), %rdi
movq %rsp, %rsi
callq 0x39b08
leaq 0x38(%rsp), %rdi
callq 0x3b616
leaq 0x18(%rsp), %rdi
callq 0xdbe8
movq (%rsp), %rdi
testq %rdi, %rdi
je 0x12074
movq (%rdi), %rax
callq *0x8(%rax)
movq %r14, %rdi
callq 0x13646
leaq 0x8(%rsp), %rcx
movl $0x2, (%rcx)
leaq 0x45fa1(%rip), %rsi     # 0x5802f
leaq 0x49ede(%rip), %rdx     # 0x5bf73
leaq 0x18(%rsp), %rdi
leaq 0x40(%rsp), %r8
callq 0x13a52
cmpb $0x0, 0x18(%rsp)
jne 0x12105
leaq 0x8(%rsp), %rdi
callq 0x3d5f6
movq 0x20(%rsp), %rax
testq %rax, %rax
je 0x120c4
movq (%rax), %r8
jmp 0x120cb
leaq 0x46f9f(%rip), %r8      # 0x5906a
leaq 0x43fe3(%rip), %rdx     # 0x560b5
movq %rsp, %rdi
pushq $0x1
popq %rsi
pushq $0x58
popq %rcx
callq 0x3b5b6
movq %rsp, %rdi
leaq 0x8(%rsp), %rsi
callq 0x39b08
movq %rsp, %rdi
callq 0x3b616
movq 0x8(%rsp), %rdi
testq %rdi, %rdi
je 0x12105
movq (%rdi), %rax
callq *0x8(%rax)
leaq 0x20(%rsp), %rdi
callq 0x13646
leaq 0x48(%rsp), %rdi
callq 0x1367e
leaq 0x68(%rsp), %rdi
callq 0x1367e
addq $0x88, %rsp
popq %rbx
popq %r14
retq
jmp 0x1213c
jmp 0x12149
jmp 0x1215e
jmp 0x12168
jmp 0x12177
jmp 0x12186
jmp 0x1219a
movq %rax, %rbx
movq %rsp, %rdi
callq 0x3b616
jmp 0x1214c
movq %rax, %rbx
movq 0x8(%rsp), %rdi
testq %rdi, %rdi
je 0x12161
movq (%rdi), %rax
callq *0x8(%rax)
jmp 0x12161
movq %rax, %rbx
leaq 0x20(%rsp), %rdi
jmp 0x121a0
movq %rax, %rbx
leaq 0x38(%rsp), %rdi
callq 0x3b616
jmp 0x1217a
movq %rax, %rbx
leaq 0x18(%rsp), %rdi
callq 0xdbe8
jmp 0x12189
movq %rax, %rbx
movq (%rsp), %rdi
testq %rdi, %rdi
je 0x1219d
movq (%rdi), %rax
callq *0x8(%rax)
jmp 0x1219d
movq %rax, %rbx
movq %r14, %rdi
callq 0x13646
jmp 0x1222d
jmp 0x121b8
jmp 0x121c7
jmp 0x121dc
jmp 0x121e6
jmp 0x121f3
jmp 0x12202
jmp 0x12217
movq %rax, %rbx
leaq 0x8(%rsp), %rdi
callq 0x3b616
jmp 0x121ca
movq %rax, %rbx
movq 0x18(%rsp), %rdi
testq %rdi, %rdi
je 0x121df
movq (%rdi), %rax
callq *0x8(%rax)
jmp 0x121df
movq %rax, %rbx
leaq 0x50(%rsp), %rdi
jmp 0x1221d
movq %rax, %rbx
movq %rsp, %rdi
callq 0x3b616
jmp 0x121f6
movq %rax, %rbx
leaq 0x48(%rsp), %rdi
callq 0xdbe8
jmp 0x12205
movq %rax, %rbx
movq 0x8(%rsp), %rdi
testq %rdi, %rdi
je 0x1221a
movq (%rdi), %rax
callq *0x8(%rax)
jmp 0x1221a
movq %rax, %rbx
movq %r14, %rdi
callq 0x13646
jmp 0x12242
jmp 0x1222a
jmp 0x1222a
jmp 0x1222a
movq %rax, %rbx
leaq 0x48(%rsp), %rdi
callq 0x1367e
jmp 0x12242
jmp 0x1223f
jmp 0x1223f
jmp 0x1223f
movq %rax, %rbx
leaq 0x68(%rsp), %rdi
callq 0x1367e
movq %rbx, %rdi
callq 0xdaa0