// File: /workspace/github_cpp_makefile_star2_O1/halfflat[P]tinyopt/test/test_run.cc
// Function: run_mandatory_Test::TestBody()
TEST(run, mandatory) {
    bool m = false, a = false;
    to::option opts[] = {
        { to::set(m), "-m", to::flag, to::mandatory },
        { to::set(a), "-a", to::flag }
    };

    mockargs M1("-a\0-m\0");
    auto r1 = to::run(opts, M1.argc, M1.argv);
    EXPECT_TRUE(r1);
    EXPECT_TRUE(a);
    EXPECT_TRUE(m);

    mockargs M2("-a\0");
    EXPECT_THROW(to::run(opts, M2.argc, M2.argv), to::missing_mandatory_option);
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x210, %rsp            # imm = 0x210
xorl %eax, %eax
leaq 0x1f(%rsp), %rcx
movb %al, (%rcx)
movb %al, 0xf(%rsp)
xorps %xmm0, %xmm0
leaq 0xf0(%rsp), %rsi
movaps %xmm0, (%rsi)
movaps %xmm0, 0x10(%rsi)
movq %rcx, (%rsi)
movb $0x1, 0x8(%rsi)
leaq 0x5793(%rip), %rbx      # 0x3e8a8
movq %rbx, 0x18(%rsi)
leaq 0x5794(%rip), %r15      # 0x3e8b4
movq %r15, 0x10(%rsi)
leaq 0xa8(%rsp), %rcx
movl $0x1, (%rcx)
leaq 0x60(%rsp), %r8
movl $0x8, (%r8)
leaq 0x3824e(%rip), %rdx     # 0x71393
leaq 0x130(%rsp), %r14
movq %r14, %rdi
callq 0x3d6fe
leaq 0x1a0(%rsp), %r14
leaq 0xd0(%rsp), %rsi
xorps %xmm0, %xmm0
movaps %xmm0, (%rsi)
movaps %xmm0, 0x10(%rsi)
leaq 0xf(%rsp), %rax
movq %rax, (%rsi)
movb $0x1, 0x8(%rsi)
movq %rbx, 0x18(%rsi)
movq %r15, 0x10(%rsi)
leaq 0x88(%rsp), %rcx
movl $0x1, (%rcx)
leaq 0x361e1(%rip), %rdx     # 0x6f379
movq %r14, %rdi
callq 0x3d1ba
movq 0xe0(%rsp), %rax
testq %rax, %rax
je 0x391bf
leaq 0xd0(%rsp), %rdi
movq %rdi, %rsi
movl $0x3, %edx
callq *%rax
movq 0x100(%rsp), %rax
testq %rax, %rax
je 0x391de
leaq 0xf0(%rsp), %rdi
movq %rdi, %rsi
movl $0x3, %edx
callq *%rax
leaq 0x385c2(%rip), %rsi     # 0x717a7
leaq 0xa8(%rsp), %rdi
callq 0x2a408
leaq 0xa8(%rsp), %rdx
movq 0x8(%rdx), %rcx
xorps %xmm0, %xmm0
leaq 0x60(%rsp), %r8
movaps %xmm0, (%r8)
movq $0x0, 0x10(%r8)
leaq 0x88(%rsp), %rdi
leaq 0x130(%rsp), %rsi
callq 0x3d2c3
leaq 0x60(%rsp), %rdi
callq 0x20fca
movb 0x88(%rsp), %al
leaq 0x48(%rsp), %r14
movb %al, -0x8(%r14)
movq $0x0, (%r14)
testb %al, %al
jne 0x392e2
leaq 0x20(%rsp), %rdi
callq 0x4e2e8
leaq 0x38074(%rip), %rdx     # 0x712d5
leaq 0x34e9e(%rip), %rcx     # 0x6e106
leaq 0x34e9d(%rip), %r8      # 0x6e10c
leaq 0x60(%rsp), %rdi
leaq 0x40(%rsp), %rsi
callq 0x48021
movq 0x60(%rsp), %r8
leaq 0x37fee(%rip), %rdx     # 0x71278
leaq 0x10(%rsp), %rdi
movl $0x1, %esi
movl $0x7b, %ecx
callq 0x4a84c
leaq 0x10(%rsp), %rdi
leaq 0x20(%rsp), %rsi
callq 0x481aa
leaq 0x10(%rsp), %rdi
callq 0x4a8b8
leaq 0x70(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x392d2
movq 0x70(%rsp), %rsi
incq %rsi
callq 0xd530
movq 0x20(%rsp), %rdi
testq %rdi, %rdi
je 0x392e2
movq (%rdi), %rax
callq *0x8(%rax)
movq 0x48(%rsp), %rsi
testq %rsi, %rsi
je 0x392f4
movq %r14, %rdi
callq 0x156d0
movb 0xf(%rsp), %al
leaq 0x48(%rsp), %r14
movb %al, -0x8(%r14)
movq $0x0, (%r14)
testb %al, %al
jne 0x393a2
leaq 0x20(%rsp), %rdi
callq 0x4e2e8
leaq 0x36059(%rip), %rdx     # 0x6f37a
leaq 0x34dde(%rip), %rcx     # 0x6e106
leaq 0x34ddd(%rip), %r8      # 0x6e10c
leaq 0x60(%rsp), %rdi
leaq 0x40(%rsp), %rsi
callq 0x48021
movq 0x60(%rsp), %r8
leaq 0x37f2e(%rip), %rdx     # 0x71278
leaq 0x10(%rsp), %rdi
movl $0x1, %esi
movl $0x7c, %ecx
callq 0x4a84c
leaq 0x10(%rsp), %rdi
leaq 0x20(%rsp), %rsi
callq 0x481aa
leaq 0x10(%rsp), %rdi
callq 0x4a8b8
leaq 0x70(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x39392
movq 0x70(%rsp), %rsi
incq %rsi
callq 0xd530
movq 0x20(%rsp), %rdi
testq %rdi, %rdi
je 0x393a2
movq (%rdi), %rax
callq *0x8(%rax)
movq 0x48(%rsp), %rsi
testq %rsi, %rsi
je 0x393b4
movq %r14, %rdi
callq 0x156d0
movb 0x1f(%rsp), %al
leaq 0x48(%rsp), %r14
movb %al, -0x8(%r14)
movq $0x0, (%r14)
testb %al, %al
jne 0x39462
leaq 0x20(%rsp), %rdi
callq 0x4e2e8
leaq 0x37fb3(%rip), %rdx     # 0x71394
leaq 0x34d1e(%rip), %rcx     # 0x6e106
leaq 0x34d1d(%rip), %r8      # 0x6e10c
leaq 0x60(%rsp), %rdi
leaq 0x40(%rsp), %rsi
callq 0x48021
movq 0x60(%rsp), %r8
leaq 0x37e6e(%rip), %rdx     # 0x71278
leaq 0x10(%rsp), %rdi
movl $0x1, %esi
movl $0x7d, %ecx
callq 0x4a84c
leaq 0x10(%rsp), %rdi
leaq 0x20(%rsp), %rsi
callq 0x481aa
leaq 0x10(%rsp), %rdi
callq 0x4a8b8
leaq 0x70(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x39452
movq 0x70(%rsp), %rsi
incq %rsi
callq 0xd530
movq 0x20(%rsp), %rdi
testq %rdi, %rdi
je 0x39462
movq (%rdi), %rax
callq *0x8(%rax)
movq 0x48(%rsp), %rsi
testq %rsi, %rsi
je 0x39474
movq %r14, %rdi
callq 0x156d0
leaq 0x3844e(%rip), %rsi     # 0x718c9
leaq 0x60(%rsp), %rdi
callq 0x2a408
xorps %xmm0, %xmm0
leaq 0x50(%rsp), %r15
movaps %xmm0, -0x10(%r15)
movaps %xmm0, (%r15)
movq %r15, -0x10(%r15)
movq $0x0, -0x8(%r15)
movb $0x0, (%r15)
callq 0x4e2e5
testb %al, %al
je 0x3950a
leaq 0x60(%rsp), %rdx
movq 0x8(%rdx), %rcx
xorps %xmm0, %xmm0
leaq 0x20(%rsp), %r8
movaps %xmm0, (%r8)
movq $0x0, 0x10(%r8)
leaq 0x110(%rsp), %rdi
leaq 0x130(%rsp), %rsi
callq 0x3d2c3
cmpb $0x1, 0x110(%rsp)
jne 0x394f8
leaq 0x118(%rsp), %rdi
callq 0x20fca
movb $0x0, 0x110(%rsp)
leaq 0x20(%rsp), %rdi
callq 0x20fca
leaq 0x40(%rsp), %rdi
movq 0x8(%rdi), %rdx
leaq 0x37f7f(%rip), %rcx     # 0x71499
movl $0x80, %r8d
xorl %esi, %esi
callq 0xd960
leaq 0x20(%rsp), %rdi
callq 0x4e2e8
movq 0x40(%rsp), %r8
leaq 0x37d3b(%rip), %rdx     # 0x71278
leaq 0x10(%rsp), %rdi
movl $0x1, %esi
movl $0x80, %ecx
callq 0x4a84c
leaq 0x10(%rsp), %rdi
leaq 0x20(%rsp), %rsi
callq 0x481aa
leaq 0x10(%rsp), %rdi
callq 0x4a8b8
movq 0x20(%rsp), %rdi
testq %rdi, %rdi
je 0x3957a
movq (%rdi), %rax
callq *0x8(%rax)
movq 0x40(%rsp), %rdi
cmpq %r15, %rdi
je 0x39591
movq 0x50(%rsp), %rsi
incq %rsi
callq 0xd530
movq 0x70(%rsp), %rdi
testq %rdi, %rdi
je 0x395ab
movq 0x80(%rsp), %rsi
subq %rdi, %rsi
callq 0xd530
cmpb $0x1, 0x88(%rsp)
jne 0x395c2
leaq 0x90(%rsp), %rdi
callq 0x20fca
movq 0xb8(%rsp), %rdi
testq %rdi, %rdi
je 0x395df
movq 0xc8(%rsp), %rsi
subq %rdi, %rsi
callq 0xd530
movl $0xe0, %r14d
leaq (%rsp,%r14), %rdi
addq $0x110, %rdi            # imm = 0x110
callq 0x21caa
leaq (%rsp,%r14), %rdi
addq $0xf8, %rdi
callq 0x21cda
leaq (%rsp,%r14), %rbx
addq $0xe0, %rbx
movq %rbx, %rdi
callq 0x21d0a
movq -0x10(%rbx), %rax
testq %rax, %rax
je 0x39636
leaq (%rsp,%r14), %rdi
addq $0xc0, %rdi
movq %rdi, %rsi
movl $0x3, %edx
callq *%rax
addq $-0x70, %r14
jne 0x395e5
addq $0x210, %rsp            # imm = 0x210
popq %rbx
popq %r14
popq %r15
retq
movq %rdx, %r14
movq %rax, %rbx
leaq 0x20(%rsp), %rdi
callq 0x20fca
jmp 0x3971e
jmp 0x3966c
jmp 0x3967d
jmp 0x3969d
jmp 0x3966c
jmp 0x396bb
jmp 0x3967d
jmp 0x3969d
movq %rax, %rbx
leaq 0x10(%rsp), %rdi
callq 0x4a8b8
jmp 0x39680
jmp 0x396bb
movq %rax, %rbx
leaq 0x70(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x396a0
movq 0x70(%rsp), %rsi
incq %rsi
callq 0xd530
jmp 0x396a0
movq %rax, %rbx
movq 0x20(%rsp), %rdi
testq %rdi, %rdi
je 0x396b0
movq (%rdi), %rax
callq *0x8(%rax)
movq $0x0, 0x20(%rsp)
jmp 0x396be
movq %rax, %rbx
movq 0x48(%rsp), %rsi
testq %rsi, %rsi
je 0x3986e
movq %r14, %rdi
callq 0x156d0
jmp 0x3986e
jmp 0x39953
jmp 0x39953
movq %rax, %rbx
leaq 0x10(%rsp), %rdi
callq 0x4a8b8
jmp 0x396f5
movq %rax, %rbx
movq 0x20(%rsp), %rdi
testq %rdi, %rdi
je 0x39705
movq (%rdi), %rax
callq *0x8(%rax)
movq $0x0, 0x20(%rsp)
jmp 0x39838
jmp 0x39835
movq %rdx, %r14
movq %rax, %rbx
movq %rbx, %rdi
cmpl $0x3, %r14d
jne 0x39736
callq 0xd200
callq 0xd9e0
jmp 0x3957a
callq 0xd200
cmpl $0x2, %r14d
jne 0x397db
movq %rax, %rbx
leaq 0x37cd1(%rip), %rsi     # 0x71420
leaq 0x40(%rsp), %rdi
callq 0xd800
movq (%rbx), %rax
movq -0x8(%rax), %rsi
leaq 0x20(%rsp), %rdi
callq 0x21880
movq 0x20(%rsp), %rsi
movq 0x28(%rsp), %rdx
leaq 0x40(%rsp), %rdi
callq 0xd180
leaq 0x30(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x39799
movq 0x30(%rsp), %rsi
incq %rsi
callq 0xd530
leaq 0x3be77(%rip), %rsi     # 0x75617
leaq 0x40(%rsp), %rdi
callq 0xdb40
movq (%rbx), %rax
movq %rbx, %rdi
callq *0x10(%rax)
leaq 0x40(%rsp), %rdi
movq %rax, %rsi
callq 0xdb40
leaq 0x35fb4(%rip), %rsi     # 0x6f77b
leaq 0x40(%rsp), %rdi
callq 0xdb40
callq 0xd9e0
jmp 0x39527
leaq 0x37bb4(%rip), %rsi     # 0x71396
leaq 0x40(%rsp), %rdi
callq 0xd800
callq 0xd9e0
jmp 0x39527
movq %rax, %rbx
callq 0xd9e0
jmp 0x39838
jmp 0x39835
movq %rax, %rbx
leaq 0x30(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x39829
movq 0x30(%rsp), %rsi
incq %rsi
callq 0xd530
jmp 0x39829
jmp 0x39826
jmp 0x39835
movq %rax, %rbx
callq 0xd9e0
jmp 0x39838
jmp 0x39953
movq %rax, %rbx
movq 0x40(%rsp), %rdi
cmpq %r15, %rdi
je 0x3984f
movq 0x50(%rsp), %rsi
incq %rsi
callq 0xd530
movq 0x70(%rsp), %rdi
testq %rdi, %rdi
je 0x3986e
movq 0x80(%rsp), %rsi
subq %rdi, %rsi
callq 0xd530
jmp 0x3986e
movq %rax, %rbx
cmpb $0x1, 0x88(%rsp)
jne 0x39885
leaq 0x90(%rsp), %rdi
callq 0x20fca
movb $0x0, 0x88(%rsp)
movq 0xb8(%rsp), %rdi
testq %rdi, %rdi
je 0x398aa
movq 0xc8(%rsp), %rsi
subq %rdi, %rsi
callq 0xd530
movl $0x70, %r14d
leaq (%rsp,%r14), %rdi
addq $0x130, %rdi            # imm = 0x130
callq 0x20f42
addq $-0x70, %r14
cmpq $-0x70, %r14
jne 0x398b0
movq %rbx, %rdi
callq 0xda70
movq %rax, %rbx
leaq 0x60(%rsp), %rdi
callq 0x20fca
jmp 0x3988d
movq %rax, %rbx
jmp 0x398aa
movq %rax, %rbx
movq 0xe0(%rsp), %rax
testq %rax, %rax
je 0x3990f
leaq 0xd0(%rsp), %rdi
movq %rdi, %rsi
movl $0x3, %edx
callq *%rax
jmp 0x3990f
jmp 0x39953
movq %rax, %rbx
movq 0x100(%rsp), %rax
testq %rax, %rax
je 0x3992e
leaq 0xf0(%rsp), %rdi
movq %rdi, %rsi
movl $0x3, %edx
callq *%rax
leaq 0x130(%rsp), %r15
cmpq %r14, %r15
je 0x398ca
addq $-0x70, %r14
movq %r14, %rdi
callq 0x20f42
cmpq %r15, %r14
jne 0x3993b
jmp 0x398ca
jmp 0x39953
movq %rax, %rdi
callq 0x15674
nop