// File: halfflat[P]tinyopt/include/tinyopt/tinyopt.h
// Function: to::impl::run(std::vector<to::impl::counted_option, std::allocator<to::impl::counted_option>>&, int&, char**)
inline maybe<saved_options> run(std::vector<impl::counted_option>& opts, int& argc, char** argv) {
        saved_options collate;
        bool exit = false;
        bool stop = false;
        state st{argc, argv};
        int mode = 0;
        while (st && !exit && !stop) {
            // Try options with a key first.
            for (auto& o: opts) {
                if (o.keys.empty()) continue;
                if (o.is_single && o.count) continue;
                if (!o.check_mode(mode)) continue;

                if (auto ma = o.match(st)) {
                    if (!o.is_ephemeral) {
                        if (ma->first) collate.add(ma->first);
                        if (ma->second) collate.add(ma->second);
                    }
                    o.set_mode(mode);
                    exit = o.is_exit;
                    stop = o.is_stop;
                    goto next;
                }
            }

            // Literal "--" terminates option parsing.
            if (!std::strcmp(*argv, "--")) {
                st.shift();
                return collate;
            }

            // Try free options.
            for (auto& o: opts) {
                if (!o.keys.empty()) continue;
                if (o.is_single && o.count) continue;
                if (!o.check_mode(mode)) continue;

                if (auto ma = o.match(st)) {
                    if (!o.is_ephemeral) collate.add(ma->second);
                    o.set_mode(mode);
                    exit = o.is_exit;
                    goto next;
                }
            }

            // Nothing matched, so increment argv.
            st.skip();
        next: ;
        }

        return exit? nothing: just(collate);
    }

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x1b0, %rsp            # imm = 0x1B0
movq %rdi, -0x160(%rbp)
movq %rdi, %rax
movq %rax, -0x158(%rbp)
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq %rcx, -0x20(%rbp)
leaq -0x38(%rbp), %rdi
callq 0x4730
movb $0x0, -0x39(%rbp)
movb $0x0, -0x3a(%rbp)
movq -0x18(%rbp), %rsi
movq -0x20(%rbp), %rdx
leaq -0x58(%rbp), %rdi
callq 0xd820
jmp 0x9ae0
movl $0x0, -0x68(%rbp)
leaq -0x58(%rbp), %rdi
callq 0xd850
movb %al, -0x161(%rbp)
jmp 0x9af8
movb -0x161(%rbp), %cl
xorl %eax, %eax
testb $0x1, %cl
movb %al, -0x162(%rbp)
jne 0x9b0d
jmp 0x9b26
xorl %eax, %eax
testb $0x1, -0x39(%rbp)
movb %al, -0x162(%rbp)
jne 0x9b26
movb -0x3a(%rbp), %al
xorb $-0x1, %al
movb %al, -0x162(%rbp)
movb -0x162(%rbp), %al
testb $0x1, %al
jne 0x9b35
jmp 0xa0ea
movq -0x10(%rbp), %rax
movq %rax, -0x70(%rbp)
movq -0x70(%rbp), %rdi
callq 0xa170
movq %rax, -0x78(%rbp)
movq -0x70(%rbp), %rdi
callq 0xa1a0
movq %rax, -0x80(%rbp)
leaq -0x78(%rbp), %rdi
leaq -0x80(%rbp), %rsi
callq 0xa1d0
testb $0x1, %al
jne 0x9b6d
jmp 0x9e56
leaq -0x78(%rbp), %rdi
callq 0xa210
movq %rax, -0x88(%rbp)
movq -0x88(%rbp), %rdi
addq $0x20, %rdi
callq 0xd870
testb $0x1, %al
jne 0x9b93
jmp 0x9ba9
jmp 0x9e37
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x60(%rbp)
movl %eax, -0x64(%rbp)
jmp 0xa135
movq -0x88(%rbp), %rax
testb $0x1, 0x6a(%rax)
je 0x9bc8
movq -0x88(%rbp), %rax
cmpl $0x0, 0x70(%rax)
je 0x9bc8
jmp 0x9e37
movq -0x88(%rbp), %rdi
movl -0x68(%rbp), %esi
callq 0xd8b0
movb %al, -0x163(%rbp)
jmp 0x9bdf
movb -0x163(%rbp), %al
testb $0x1, %al
jne 0x9bf0
jmp 0x9beb
jmp 0x9e37
movq -0x88(%rbp), %rsi
leaq -0xa0(%rbp), %rdi
leaq -0x58(%rbp), %rdx
callq 0xd940
jmp 0x9c09
leaq -0xa0(%rbp), %rdi
callq 0xdcc0
testb $0x1, %al
jne 0x9c1e
jmp 0x9df9
movq -0x88(%rbp), %rax
testb $0x1, 0x69(%rax)
jne 0x9daf
leaq -0xa0(%rbp), %rdi
callq 0xdce0
cmpq $0x0, (%rax)
je 0x9ced
leaq -0xa0(%rbp), %rdi
callq 0xdce0
movq (%rax), %rax
movq %rax, -0x178(%rbp)
leaq -0xc1(%rbp), %rdi
movq %rdi, -0x170(%rbp)
callq 0x3330
movq -0x178(%rbp), %rsi
movq -0x170(%rbp), %rdx
leaq -0xc0(%rbp), %rdi
callq 0x4000
jmp 0x9c8a
leaq -0x38(%rbp), %rdi
leaq -0xc0(%rbp), %rsi
callq 0xdd00
jmp 0x9c9c
leaq -0xc0(%rbp), %rdi
callq 0x3130
leaq -0xc1(%rbp), %rdi
callq 0x3210
jmp 0x9ced
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x60(%rbp)
movl %eax, -0x64(%rbp)
jmp 0x9cdc
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x60(%rbp)
movl %eax, -0x64(%rbp)
leaq -0xc0(%rbp), %rdi
callq 0x3130
leaq -0xc1(%rbp), %rdi
callq 0x3210
jmp 0x9e45
leaq -0xa0(%rbp), %rdi
callq 0xdce0
cmpq $0x0, 0x8(%rax)
je 0x9dad
leaq -0xa0(%rbp), %rdi
callq 0xdce0
movq 0x8(%rax), %rax
movq %rax, -0x188(%rbp)
leaq -0xe9(%rbp), %rdi
movq %rdi, -0x180(%rbp)
callq 0x3330
movq -0x188(%rbp), %rsi
movq -0x180(%rbp), %rdx
leaq -0xe8(%rbp), %rdi
callq 0x4000
jmp 0x9d4a
leaq -0x38(%rbp), %rdi
leaq -0xe8(%rbp), %rsi
callq 0xdd00
jmp 0x9d5c
leaq -0xe8(%rbp), %rdi
callq 0x3130
leaq -0xe9(%rbp), %rdi
callq 0x3210
jmp 0x9dad
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x60(%rbp)
movl %eax, -0x64(%rbp)
jmp 0x9d9c
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x60(%rbp)
movl %eax, -0x64(%rbp)
leaq -0xe8(%rbp), %rdi
callq 0x3130
leaq -0xe9(%rbp), %rdi
callq 0x3210
jmp 0x9e45
jmp 0x9daf
movq -0x88(%rbp), %rdi
leaq -0x68(%rbp), %rsi
callq 0xdd20
jmp 0x9dc1
movq -0x88(%rbp), %rax
movb 0x6c(%rax), %al
andb $0x1, %al
movb %al, -0x39(%rbp)
movq -0x88(%rbp), %rax
movb 0x6d(%rax), %al
andb $0x1, %al
movb %al, -0x3a(%rbp)
movl $0x6, -0xf0(%rbp)
jmp 0x9e03
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x60(%rbp)
movl %eax, -0x64(%rbp)
jmp 0x9e45
movl $0x0, -0xf0(%rbp)
leaq -0xa0(%rbp), %rdi
callq 0xdda0
movl -0xf0(%rbp), %eax
movl %eax, -0x18c(%rbp)
testl %eax, %eax
je 0x9e35
jmp 0x9e21
movl -0x18c(%rbp), %eax
subl $0x6, %eax
je 0xa0e5
jmp 0xa11c
jmp 0x9e37
leaq -0x78(%rbp), %rdi
callq 0xa410
jmp 0x9b57
leaq -0xa0(%rbp), %rdi
callq 0xdda0
jmp 0xa135
movq -0x20(%rbp), %rax
movq (%rax), %rdi
leaq 0x730d(%rip), %rsi      # 0x11171
callq 0x32a0
cmpl $0x0, %eax
jne 0x9e9f
leaq -0x58(%rbp), %rdi
movl $0x1, %esi
callq 0xddd0
jmp 0x9e7e
movq -0x160(%rbp), %rdi
leaq -0x38(%rbp), %rsi
callq 0xdea0
jmp 0x9e90
movl $0x1, -0xf0(%rbp)
jmp 0xa11c
movq -0x10(%rbp), %rax
movq %rax, -0xf8(%rbp)
movq -0xf8(%rbp), %rdi
callq 0xa170
movq %rax, -0x100(%rbp)
movq -0xf8(%rbp), %rdi
callq 0xa1a0
movq %rax, -0x108(%rbp)
leaq -0x100(%rbp), %rdi
leaq -0x108(%rbp), %rsi
callq 0xa1d0
testb $0x1, %al
jne 0x9eec
jmp 0xa0d8
leaq -0x100(%rbp), %rdi
callq 0xa210
movq %rax, -0x110(%rbp)
movq -0x110(%rbp), %rdi
addq $0x20, %rdi
callq 0xd870
testb $0x1, %al
jne 0x9f18
jmp 0xa0b9
movq -0x110(%rbp), %rax
testb $0x1, 0x6a(%rax)
je 0x9f37
movq -0x110(%rbp), %rax
cmpl $0x0, 0x70(%rax)
je 0x9f37
jmp 0xa0b9
movq -0x110(%rbp), %rdi
movl -0x68(%rbp), %esi
callq 0xd8b0
movb %al, -0x18d(%rbp)
jmp 0x9f4e
movb -0x18d(%rbp), %al
testb $0x1, %al
jne 0x9f5f
jmp 0x9f5a
jmp 0xa0b9
movq -0x110(%rbp), %rsi
leaq -0x128(%rbp), %rdi
leaq -0x58(%rbp), %rdx
callq 0xd940
jmp 0x9f78
leaq -0x128(%rbp), %rdi
callq 0xdcc0
testb $0x1, %al
jne 0x9f8d
jmp 0xa082
movq -0x110(%rbp), %rax
testb $0x1, 0x69(%rax)
jne 0xa047
leaq -0x128(%rbp), %rdi
callq 0xdce0
movq 0x8(%rax), %rax
movq %rax, -0x1a0(%rbp)
leaq -0x149(%rbp), %rdi
movq %rdi, -0x198(%rbp)
callq 0x3330
movq -0x1a0(%rbp), %rsi
movq -0x198(%rbp), %rdx
leaq -0x148(%rbp), %rdi
callq 0x4000
jmp 0x9fe4
leaq -0x38(%rbp), %rdi
leaq -0x148(%rbp), %rsi
callq 0xdd00
jmp 0x9ff6
leaq -0x148(%rbp), %rdi
callq 0x3130
leaq -0x149(%rbp), %rdi
callq 0x3210
jmp 0xa047
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x60(%rbp)
movl %eax, -0x64(%rbp)
jmp 0xa036
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x60(%rbp)
movl %eax, -0x64(%rbp)
leaq -0x148(%rbp), %rdi
callq 0x3130
leaq -0x149(%rbp), %rdi
callq 0x3210
jmp 0xa0ca
movq -0x110(%rbp), %rdi
leaq -0x68(%rbp), %rsi
callq 0xdd20
jmp 0xa059
movq -0x110(%rbp), %rax
movb 0x6c(%rax), %al
andb $0x1, %al
movb %al, -0x39(%rbp)
movl $0x6, -0xf0(%rbp)
jmp 0xa08c
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x60(%rbp)
movl %eax, -0x64(%rbp)
jmp 0xa0ca
movl $0x0, -0xf0(%rbp)
leaq -0x128(%rbp), %rdi
callq 0xdda0
movl -0xf0(%rbp), %eax
movl %eax, -0x1a4(%rbp)
testl %eax, %eax
je 0xa0b7
jmp 0xa0aa
movl -0x1a4(%rbp), %eax
subl $0x6, %eax
je 0xa0e5
jmp 0xa11c
jmp 0xa0b9
leaq -0x100(%rbp), %rdi
callq 0xa410
jmp 0x9ed0
leaq -0x128(%rbp), %rdi
callq 0xdda0
jmp 0xa135
leaq -0x58(%rbp), %rdi
callq 0xded0
jmp 0xa0e3
jmp 0xa0e5
jmp 0x9ae7
testb $0x1, -0x39(%rbp)
je 0xa0fe
movq -0x160(%rbp), %rdi
callq 0xa4d0
jmp 0xa112
movq -0x160(%rbp), %rdi
leaq -0x38(%rbp), %rsi
callq 0xdf00
jmp 0xa110
jmp 0xa112
movl $0x1, -0xf0(%rbp)
leaq -0x38(%rbp), %rdi
callq 0x4780
movq -0x158(%rbp), %rax
addq $0x1b0, %rsp            # imm = 0x1B0
popq %rbp
retq
leaq -0x38(%rbp), %rdi
callq 0x4780
movq -0x60(%rbp), %rdi
callq 0x3320
nopw (%rax,%rax)