// File: /workspace/github_cpp_makefile_star2_O1/halfflat[P]tinyopt/test/test_run.cc
// Function: run_modal_Test::TestBody()
TEST(run, modal) {
    int a0 = 0, a1 = 0, a2 = 0;
    to::option opts[] = {
        {to::increment(a0), "-a", to::flag, to::when(0)},
        {to::increment(a1), "-a", to::flag, to::when(1)},
        {to::increment(a2), "-a", to::flag, to::when(2)},
        {{}, "one", to::flag, to::then(1)},
        {{}, "two", to::flag, to::then(2)}
    };

    mockargs M("-a\0one\0-a\0two\0-a\0-a\0one\0-a\0-a\0");
    auto r = to::run(opts, M.argc, M.argv);
    EXPECT_TRUE(r);

    EXPECT_EQ(1, a0);
    EXPECT_EQ(3, a1);
    EXPECT_EQ(2, a2);
}

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x3b0, %rsp            # imm = 0x3B0
xorl %eax, %eax
leaq 0x7c(%rsp), %rcx
movl %eax, (%rcx)
movl %eax, 0x4c(%rsp)
movl %eax, 0x48(%rsp)
xorps %xmm0, %xmm0
leaq 0x160(%rsp), %rsi
movaps %xmm0, (%rsi)
movaps %xmm0, 0x10(%rsi)
movq %rcx, (%rsi)
leaq -0x260a9(%rip), %rbx    # 0x1676c
movq %rbx, 0x18(%rsi)
leaq -0x260ac(%rip), %r15    # 0x16774
movq %r15, 0x10(%rsi)
leaq 0x70(%rsp), %rcx
movl $0x1, (%rcx)
leaq 0xa0(%rsp), %r8
movaps %xmm0, 0x10(%r8)
movaps %xmm0, (%r8)
leaq -0x1abf5(%rip), %r12    # 0x21c52
movq %r12, 0x18(%r8)
leaq -0x1abf8(%rip), %r13    # 0x21c5a
movq %r13, 0x10(%r8)
leaq 0x32b1c(%rip), %rdx     # 0x6f379
leaq 0x180(%rsp), %r14
movq %r14, %rdi
callq 0x3deb6
leaq 0x1f0(%rsp), %r14
leaq 0x140(%rsp), %rsi
xorps %xmm0, %xmm0
movaps %xmm0, (%rsi)
movaps %xmm0, 0x10(%rsi)
leaq 0x4c(%rsp), %rax
movq %rax, (%rsi)
movq %rbx, 0x18(%rsi)
movq %r15, 0x10(%rsi)
movl $0x1, %eax
leaq 0xdc(%rsp), %rcx
movl %eax, (%rcx)
leaq 0x80(%rsp), %r8
movaps %xmm0, (%r8)
movaps %xmm0, 0x10(%r8)
movl %eax, (%r8)
movq %r12, 0x18(%r8)
movq %r13, 0x10(%r8)
leaq 0x32ab0(%rip), %rdx     # 0x6f379
movq %r14, %rdi
callq 0x3deb6
leaq 0x260(%rsp), %r14
xorps %xmm0, %xmm0
leaq 0x120(%rsp), %rsi
movaps %xmm0, (%rsi)
movaps %xmm0, 0x10(%rsi)
leaq 0x48(%rsp), %rax
movq %rax, (%rsi)
movq %rbx, 0x18(%rsi)
movq %r15, 0x10(%rsi)
leaq 0xd8(%rsp), %rcx
movl $0x1, (%rcx)
movq %rsp, %r8
movaps %xmm0, (%r8)
movaps %xmm0, 0x10(%r8)
movl $0x2, (%r8)
movq %r12, 0x18(%r8)
movq %r13, 0x10(%r8)
leaq 0x32a4e(%rip), %rdx     # 0x6f379
movq %r14, %rdi
callq 0x3deb6
leaq 0x2d0(%rsp), %r14
leaq 0x100(%rsp), %rsi
xorps %xmm0, %xmm0
movaps %xmm0, (%rsi)
leaq 0x1f3c(%rip), %rbx      # 0x3e88c
movq %rbx, 0x18(%rsi)
leaq 0x1f35(%rip), %r15      # 0x3e890
movq %r15, 0x10(%rsi)
movl $0x1, %eax
leaq 0xd4(%rsp), %rcx
movl %eax, (%rcx)
leaq 0x20(%rsp), %r8
movaps %xmm0, (%r8)
movaps %xmm0, 0x10(%r8)
movl %eax, (%r8)
leaq -0x1ad06(%rip), %r12    # 0x21c80
movq %r12, 0x18(%r8)
leaq -0x1ad0d(%rip), %r13    # 0x21c84
movq %r13, 0x10(%r8)
leaq 0x34113(%rip), %rdx     # 0x70aaf
movq %r14, %rdi
callq 0x3dfc6
leaq 0x340(%rsp), %r14
xorps %xmm0, %xmm0
leaq 0xe0(%rsp), %rsi
movaps %xmm0, (%rsi)
movq %rbx, 0x18(%rsi)
movq %r15, 0x10(%rsi)
leaq 0xd0(%rsp), %rcx
movl $0x1, (%rcx)
leaq 0x50(%rsp), %r8
movaps %xmm0, (%r8)
movaps %xmm0, 0x10(%r8)
movl $0x2, (%r8)
movq %r12, 0x18(%r8)
movq %r13, 0x10(%r8)
leaq 0x34203(%rip), %rdx     # 0x70bf7
movq %r14, %rdi
callq 0x3dfc6
movq 0x60(%rsp), %rax
testq %rax, %rax
je 0x3ca15
leaq 0x50(%rsp), %rdi
movq %rdi, %rsi
movl $0x3, %edx
callq *%rax
movq 0xf0(%rsp), %rax
testq %rax, %rax
je 0x3ca34
leaq 0xe0(%rsp), %rdi
movq %rdi, %rsi
movl $0x3, %edx
callq *%rax
movq 0x30(%rsp), %rax
testq %rax, %rax
je 0x3ca4d
leaq 0x20(%rsp), %rdi
movq %rdi, %rsi
movl $0x3, %edx
callq *%rax
movq 0x110(%rsp), %rax
testq %rax, %rax
je 0x3ca6c
leaq 0x100(%rsp), %rdi
movq %rdi, %rsi
movl $0x3, %edx
callq *%rax
movq 0x10(%rsp), %rax
testq %rax, %rax
je 0x3ca83
movq %rsp, %rdi
movq %rdi, %rsi
movl $0x3, %edx
callq *%rax
movq 0x130(%rsp), %rax
testq %rax, %rax
je 0x3caa2
leaq 0x120(%rsp), %rdi
movq %rdi, %rsi
movl $0x3, %edx
callq *%rax
movq 0x90(%rsp), %rax
testq %rax, %rax
je 0x3cac1
leaq 0x80(%rsp), %rdi
movq %rdi, %rsi
movl $0x3, %edx
callq *%rax
movq 0x150(%rsp), %rax
testq %rax, %rax
je 0x3cae0
leaq 0x140(%rsp), %rdi
movq %rdi, %rsi
movl $0x3, %edx
callq *%rax
movq 0xb0(%rsp), %rax
testq %rax, %rax
je 0x3caff
leaq 0xa0(%rsp), %rdi
movq %rdi, %rsi
movl $0x3, %edx
callq *%rax
movq 0x170(%rsp), %rax
testq %rax, %rax
je 0x3cb1e
leaq 0x160(%rsp), %rdi
movq %rdi, %rsi
movl $0x3, %edx
callq *%rax
leaq 0x34c9c(%rip), %rsi     # 0x717c1
leaq 0xa0(%rsp), %rdi
callq 0x2a408
leaq 0xa0(%rsp), %rdx
movq 0x8(%rdx), %rcx
xorps %xmm0, %xmm0
movq %rsp, %r8
movaps %xmm0, (%r8)
movq $0x0, 0x10(%r8)
leaq 0x80(%rsp), %rdi
leaq 0x180(%rsp), %rsi
callq 0x3e0d6
movq %rsp, %rdi
callq 0x20fca
movb 0x80(%rsp), %al
leaq 0x28(%rsp), %r14
movb %al, -0x8(%r14)
movq $0x0, (%r14)
testb %al, %al
jne 0x3cc1b
leaq 0x50(%rsp), %rdi
callq 0x4e2e8
leaq 0x33837(%rip), %rdx     # 0x703d4
leaq 0x31562(%rip), %rcx     # 0x6e106
leaq 0x31561(%rip), %r8      # 0x6e10c
movq %rsp, %rdi
leaq 0x20(%rsp), %rsi
callq 0x48021
movq (%rsp), %r8
leaq 0x346b5(%rip), %rdx     # 0x71278
leaq 0x70(%rsp), %rdi
movl $0x1, %esi
movl $0xf7, %ecx
callq 0x4a84c
leaq 0x70(%rsp), %rdi
leaq 0x50(%rsp), %rsi
callq 0x481aa
leaq 0x70(%rsp), %rdi
callq 0x4a8b8
leaq 0x10(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x3cc0b
movq 0x10(%rsp), %rsi
incq %rsi
callq 0xd530
movq 0x50(%rsp), %rdi
testq %rdi, %rdi
je 0x3cc1b
movq (%rdi), %rax
callq *0x8(%rax)
movq 0x28(%rsp), %rsi
testq %rsi, %rsi
je 0x3cc2d
movq %r14, %rdi
callq 0x156d0
leaq 0x20(%rsp), %rcx
movl $0x1, (%rcx)
leaq 0x33390(%rip), %rsi     # 0x6ffcf
leaq 0x34aff(%rip), %rdx     # 0x71745
movq %rsp, %rdi
leaq 0x7c(%rsp), %r8
callq 0x15aba
cmpb $0x0, (%rsp)
jne 0x3ccbd
leaq 0x20(%rsp), %rdi
callq 0x4e2e8
movq 0x8(%rsp), %rax
testq %rax, %rax
je 0x3cc72
movq (%rax), %r8
jmp 0x3cc79
leaq 0x3437f(%rip), %r8      # 0x70ff8
leaq 0x345f8(%rip), %rdx     # 0x71278
leaq 0x50(%rsp), %rdi
movl $0x1, %esi
movl $0xf9, %ecx
callq 0x4a84c
leaq 0x50(%rsp), %rdi
leaq 0x20(%rsp), %rsi
callq 0x481aa
leaq 0x50(%rsp), %rdi
callq 0x4a8b8
movq 0x20(%rsp), %rdi
testq %rdi, %rdi
je 0x3ccbd
movq (%rdi), %rax
callq *0x8(%rax)
movq 0x8(%rsp), %rsi
testq %rsi, %rsi
je 0x3ccd1
leaq 0x8(%rsp), %rdi
callq 0x156d0
leaq 0x20(%rsp), %rcx
movl $0x3, (%rcx)
leaq 0x33e09(%rip), %rsi     # 0x70aec
leaq 0x34a5e(%rip), %rdx     # 0x71748
movq %rsp, %rdi
leaq 0x4c(%rsp), %r8
callq 0x15aba
cmpb $0x0, (%rsp)
jne 0x3cd61
leaq 0x20(%rsp), %rdi
callq 0x4e2e8
movq 0x8(%rsp), %rax
testq %rax, %rax
je 0x3cd16
movq (%rax), %r8
jmp 0x3cd1d
leaq 0x342db(%rip), %r8      # 0x70ff8
leaq 0x34554(%rip), %rdx     # 0x71278
leaq 0x50(%rsp), %rdi
movl $0x1, %esi
movl $0xfa, %ecx
callq 0x4a84c
leaq 0x50(%rsp), %rdi
leaq 0x20(%rsp), %rsi
callq 0x481aa
leaq 0x50(%rsp), %rdi
callq 0x4a8b8
movq 0x20(%rsp), %rdi
testq %rdi, %rdi
je 0x3cd61
movq (%rdi), %rax
callq *0x8(%rax)
movq 0x8(%rsp), %rsi
testq %rsi, %rsi
je 0x3cd75
leaq 0x8(%rsp), %rdi
callq 0x156d0
leaq 0x20(%rsp), %rcx
movl $0x2, (%rcx)
leaq 0x33238(%rip), %rsi     # 0x6ffbf
leaq 0x349bd(%rip), %rdx     # 0x7174b
movq %rsp, %rdi
leaq 0x48(%rsp), %r8
callq 0x15aba
cmpb $0x0, (%rsp)
jne 0x3ce05
leaq 0x20(%rsp), %rdi
callq 0x4e2e8
movq 0x8(%rsp), %rax
testq %rax, %rax
je 0x3cdba
movq (%rax), %r8
jmp 0x3cdc1
leaq 0x34237(%rip), %r8      # 0x70ff8
leaq 0x344b0(%rip), %rdx     # 0x71278
leaq 0x50(%rsp), %rdi
movl $0x1, %esi
movl $0xfb, %ecx
callq 0x4a84c
leaq 0x50(%rsp), %rdi
leaq 0x20(%rsp), %rsi
callq 0x481aa
leaq 0x50(%rsp), %rdi
callq 0x4a8b8
movq 0x20(%rsp), %rdi
testq %rdi, %rdi
je 0x3ce05
movq (%rdi), %rax
callq *0x8(%rax)
movq 0x8(%rsp), %rsi
testq %rsi, %rsi
je 0x3ce19
leaq 0x8(%rsp), %rdi
callq 0x156d0
cmpb $0x1, 0x80(%rsp)
jne 0x3ce30
leaq 0x88(%rsp), %rdi
callq 0x20fca
movq 0xb0(%rsp), %rdi
testq %rdi, %rdi
je 0x3ce4d
movq 0xc0(%rsp), %rsi
subq %rdi, %rsi
callq 0xd530
movl $0x230, %r14d           # imm = 0x230
leaq (%rsp,%r14), %rdi
addq $0x160, %rdi            # imm = 0x160
callq 0x21caa
leaq (%rsp,%r14), %rdi
addq $0x148, %rdi            # imm = 0x148
callq 0x21cda
leaq (%rsp,%r14), %rbx
addq $0x130, %rbx            # imm = 0x130
movq %rbx, %rdi
callq 0x21d0a
movq -0x10(%rbx), %rax
testq %rax, %rax
je 0x3cea4
leaq (%rsp,%r14), %rdi
addq $0x110, %rdi            # imm = 0x110
movq %rdi, %rsi
movl $0x3, %edx
callq *%rax
addq $-0x70, %r14
jne 0x3ce53
addq $0x3b0, %rsp            # imm = 0x3B0
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
jmp 0x3cec7
jmp 0x3ced6
jmp 0x3cef4
jmp 0x3cec7
jmp 0x3ced6
jmp 0x3cef4
movq %rax, %rbx
leaq 0x50(%rsp), %rdi
callq 0x4a8b8
jmp 0x3ced9
movq %rax, %rbx
movq 0x20(%rsp), %rdi
testq %rdi, %rdi
je 0x3cee9
movq (%rdi), %rax
callq *0x8(%rax)
movq $0x0, 0x20(%rsp)
jmp 0x3cef7
movq %rax, %rbx
movq 0x8(%rsp), %rsi
testq %rsi, %rsi
je 0x3cf0b
leaq 0x8(%rsp), %rdi
callq 0x156d0
movq $0x0, 0x8(%rsp)
jmp 0x3cfb6
movq %rax, %rbx
leaq 0x70(%rsp), %rdi
callq 0x4a8b8
jmp 0x3cf2b
movq %rax, %rbx
leaq 0x10(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x3cf4b
movq 0x10(%rsp), %rsi
incq %rsi
callq 0xd530
jmp 0x3cf4b
movq %rax, %rbx
movq 0x50(%rsp), %rdi
testq %rdi, %rdi
je 0x3cf5b
movq (%rdi), %rax
callq *0x8(%rax)
movq $0x0, 0x50(%rsp)
jmp 0x3cf69
movq %rax, %rbx
movq 0x28(%rsp), %rsi
testq %rsi, %rsi
je 0x3cfb6
movq %r14, %rdi
callq 0x156d0
jmp 0x3cfb6
jmp 0x3d1b2
jmp 0x3d1b2
jmp 0x3d1b2
jmp 0x3d1b2
jmp 0x3d1b2
jmp 0x3d1b2
jmp 0x3d1b2
jmp 0x3d1b2
jmp 0x3d1b2
jmp 0x3d1b2
jmp 0x3cfb3
jmp 0x3cfb3
movq %rax, %rbx
cmpb $0x1, 0x80(%rsp)
jne 0x3cfcd
leaq 0x88(%rsp), %rdi
callq 0x20fca
movb $0x0, 0x80(%rsp)
movq 0xb0(%rsp), %rdi
testq %rdi, %rdi
je 0x3cff2
movq 0xc0(%rsp), %rsi
subq %rdi, %rsi
callq 0xd530
movl $0x1c0, %r14d           # imm = 0x1C0
leaq (%rsp,%r14), %rdi
addq $0x180, %rdi            # imm = 0x180
callq 0x20f42
addq $-0x70, %r14
cmpq $-0x70, %r14
jne 0x3cff8
movq %rbx, %rdi
callq 0xda70
movq %rax, %rbx
movq %rsp, %rdi
callq 0x20fca
jmp 0x3cfd5
movq %rax, %rbx
jmp 0x3cff2
movq %rax, %rbx
movq 0x60(%rsp), %rax
testq %rax, %rax
je 0x3d048
leaq 0x50(%rsp), %rdi
movq %rdi, %rsi
movl $0x3, %edx
callq *%rax
movq 0xf0(%rsp), %rax
testq %rax, %rax
je 0x3d076
leaq 0xe0(%rsp), %rdi
movq %rdi, %rsi
movl $0x3, %edx
callq *%rax
jmp 0x3d076
jmp 0x3d1b2
jmp 0x3d1b2
movq %rax, %rbx
movq 0x30(%rsp), %rax
testq %rax, %rax
je 0x3d08f
leaq 0x20(%rsp), %rdi
movq %rdi, %rsi
movl $0x3, %edx
callq *%rax
movq 0x110(%rsp), %rax
testq %rax, %rax
je 0x3d0bd
leaq 0x100(%rsp), %rdi
movq %rdi, %rsi
movl $0x3, %edx
callq *%rax
jmp 0x3d0bd
jmp 0x3d1b2
jmp 0x3d1b2
movq %rax, %rbx
movq 0x10(%rsp), %rax
testq %rax, %rax
je 0x3d0d4
movq %rsp, %rdi
movq %rdi, %rsi
movl $0x3, %edx
callq *%rax
movq 0x130(%rsp), %rax
testq %rax, %rax
je 0x3d102
leaq 0x120(%rsp), %rdi
movq %rdi, %rsi
movl $0x3, %edx
callq *%rax
jmp 0x3d102
jmp 0x3d1b2
jmp 0x3d1b2
movq %rax, %rbx
movq 0x90(%rsp), %rax
testq %rax, %rax
je 0x3d121
leaq 0x80(%rsp), %rdi
movq %rdi, %rsi
movl $0x3, %edx
callq *%rax
movq 0x150(%rsp), %rax
testq %rax, %rax
je 0x3d149
leaq 0x140(%rsp), %rdi
movq %rdi, %rsi
movl $0x3, %edx
callq *%rax
jmp 0x3d149
jmp 0x3d1b2
jmp 0x3d1b2
movq %rax, %rbx
movq 0xb0(%rsp), %rax
testq %rax, %rax
je 0x3d168
leaq 0xa0(%rsp), %rdi
movq %rdi, %rsi
movl $0x3, %edx
callq *%rax
movq 0x170(%rsp), %rax
testq %rax, %rax
je 0x3d187
leaq 0x160(%rsp), %rdi
movq %rdi, %rsi
movl $0x3, %edx
callq *%rax
leaq 0x180(%rsp), %r15
cmpq %r14, %r15
je 0x3d012
addq $-0x70, %r14
movq %r14, %rdi
callq 0x20f42
cmpq %r15, %r14
jne 0x3d198
jmp 0x3d012
jmp 0x3d1b2
jmp 0x3d1b2
movq %rax, %rdi
callq 0x15674