// File: /workspace/github_cpp_makefile_star2_O2/xelia-it[P]mustache/third-party/catch2/single_include/catch2/catch.hpp
// Function: Catch::Capturer::Capturer(Catch::StringRef, Catch::SourceLineInfo const&, Catch::ResultWas::OfType, Catch::StringRef)
Capturer::Capturer( StringRef macroName, SourceLineInfo const& lineInfo, ResultWas::OfType resultType, StringRef names ) {
        auto trimmed = [&] (size_t start, size_t end) {
            while (names[start] == ',' || isspace(static_cast<unsigned char>(names[start]))) {
                ++start;
            }
            while (names[end] == ',' || isspace(static_cast<unsigned char>(names[end]))) {
                --end;
            }
            return names.substr(start, end - start + 1);
        };
        auto skipq = [&] (size_t start, char quote) {
            for (auto i = start + 1; i < names.size() ; ++i) {
                if (names[i] == quote)
                    return i;
                if (names[i] == '\\')
                    ++i;
            }
            CATCH_INTERNAL_ERROR("CAPTURE parsing encountered unmatched quote");
        };

        size_t start = 0;
        std::stack<char> openings;
        for (size_t pos = 0; pos < names.size(); ++pos) {
            char c = names[pos];
            switch (c) {
            case '[':
            case '{':
            case '(':
            // It is basically impossible to disambiguate between
            // comparison and start of template args in this context
//            case '<':
                openings.push(c);
                break;
            case ']':
            case '}':
            case ')':
//           case '>':
                openings.pop();
                break;
            case '"':
            case '\'':
                pos = skipq(pos, c);
                break;
            case ',':
                if (start != pos && openings.empty()) {
                    m_messages.emplace_back(macroName, lineInfo, resultType);
                    m_messages.back().message = static_cast<std::string>(trimmed(start, pos));
                    m_messages.back().message += " := ";
                    start = pos;
                }
            }
        }
        assert(openings.empty() && "Mismatched openings");
        m_messages.emplace_back(macroName, lineInfo, resultType);
        m_messages.back().message = static_cast<std::string>(trimmed(start, names.size() - 1));
        m_messages.back().message += " := ";
    }

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0xd8, %rsp
movq %rcx, -0x68(%rbp)
movq %rdi, %r14
movq %rsi, -0x80(%rbp)
movq %rdx, -0x78(%rbp)
movl %r8d, -0x3c(%rbp)
xorps %xmm0, %xmm0
movups %xmm0, (%rdi)
andq $0x0, 0x10(%rdi)
callq 0x25825
leaq 0x10(%rbp), %r15
movq %rax, 0x18(%r14)
movq %r14, -0x38(%rbp)
andq $0x0, 0x20(%r14)
movq %r15, -0x70(%rbp)
leaq -0xf0(%rbp), %rdi
callq 0x3e88a
movq $0x0, -0x48(%rbp)
leaq -0xf0(%rbp), %r14
leaq 0x44dd8(%rip), %r12     # 0x7210c
xorl %ebx, %ebx
cmpq 0x8(%r15), %rbx
jae 0x2d48c
movq %r15, %rdi
movq %rbx, %rsi
callq 0x3e8aa
movl %eax, %r13d
movb %al, -0x29(%rbp)
movzbl %al, %eax
leal -0x22(%rax), %ecx
cmpl $0xa, %ecx
ja 0x2d3a0
movslq (%r12,%rcx,4), %rax
addq %r12, %rax
jmpq *%rax
movq %r14, %r12
leaq 0x1(%rbx), %r14
cmpq 0x8(%r15), %r14
jae 0x2d534
movq %r15, %rdi
movq %r14, %rsi
callq 0x3e8aa
cmpb %r13b, %al
je 0x2d3d6
movq %r15, %rdi
movq %r14, %rsi
callq 0x3e8aa
cmpb $0x5c, %al
je 0x2d39a
movq %r14, %rbx
jmp 0x2d368
addq $0x2, %rbx
jmp 0x2d368
cmpl $0x5b, %eax
je 0x2d3c5
cmpl $0x5d, %eax
je 0x2d3b8
cmpl $0x7b, %eax
je 0x2d3c5
cmpl $0x7d, %eax
jne 0x2d484
movq %r14, %rdi
callq 0x57616
jmp 0x2d484
movq %r14, %rdi
leaq -0x29(%rbp), %rsi
callq 0x573d8
jmp 0x2d484
movq %r14, %rbx
movq %r12, %r14
leaq 0x44d29(%rip), %r12     # 0x7210c
jmp 0x2d484
movq -0x48(%rbp), %rax
cmpq %rbx, %rax
jne 0x2d3f9
movq %rax, %rbx
jmp 0x2d484
movq -0xc0(%rbp), %rax
cmpq -0xe0(%rbp), %rax
leaq -0xa0(%rbp), %r13
jne 0x2d484
movq -0x38(%rbp), %rdi
leaq -0x80(%rbp), %rsi
movq -0x68(%rbp), %rdx
leaq -0x3c(%rbp), %rcx
callq 0x3e8da
leaq -0x70(%rbp), %rdi
movq -0x48(%rbp), %rsi
movq %rbx, %rdx
callq 0x2d61a
movq %rax, -0x60(%rbp)
movq %rdx, -0x58(%rbp)
movq %r13, %rdi
leaq -0x60(%rbp), %rsi
callq 0x3d4fc
movq -0x38(%rbp), %r14
movq 0x8(%r14), %rdi
addq $-0x38, %rdi
movq %r13, %rsi
callq 0x24690
movq %r13, %rdi
callq 0x24ad8
movq 0x8(%r14), %rdi
addq $-0x38, %rdi
leaq 0x46e51(%rip), %rsi     # 0x742c5
callq 0x24a10
movq %rbx, -0x48(%rbp)
leaq -0xf0(%rbp), %r14
incq %rbx
jmp 0x2d336
movq -0xc0(%rbp), %rax
cmpq -0xe0(%rbp), %rax
jne 0x2d59f
leaq -0x80(%rbp), %rsi
leaq -0x3c(%rbp), %rcx
movq -0x38(%rbp), %r14
movq %r14, %rdi
movq -0x68(%rbp), %rdx
callq 0x3e8da
movq -0x48(%rbp), %rsi
movq 0x8(%r15), %rdx
decq %rdx
leaq -0x70(%rbp), %rdi
callq 0x2d61a
leaq -0x60(%rbp), %rsi
movq %rax, (%rsi)
movq %rdx, 0x8(%rsi)
leaq -0xa0(%rbp), %rdi
callq 0x3d4fc
movq 0x8(%r14), %rdi
addq $-0x38, %rdi
leaq -0xa0(%rbp), %rbx
movq %rbx, %rsi
callq 0x24690
movq %rbx, %rdi
callq 0x24ad8
movq 0x8(%r14), %rdi
addq $-0x38, %rdi
leaq 0x46db4(%rip), %rsi     # 0x742c5
callq 0x24a10
leaq -0xf0(%rbp), %rdi
callq 0x45686
addq $0xd8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
leaq -0x60(%rbp), %rdi
callq 0x30e18
leaq 0x46969(%rip), %rax     # 0x73ead
leaq -0x100(%rbp), %rsi
movq %rax, (%rsi)
movq $0x2e6b, 0x8(%rsi)      # imm = 0x2E6B
movq -0x50(%rbp), %rdi
callq 0x2921b
movq -0x50(%rbp), %rdi
leaq 0x46bd9(%rip), %rsi     # 0x74143
callq 0x24570
movq -0x50(%rbp), %rdi
leaq 0x48451(%rip), %rsi     # 0x759cb
callq 0x24570
movq -0x50(%rbp), %rsi
addq $0x8, %rsi
leaq -0xa0(%rbp), %rdi
callq 0x24830
leaq -0xa0(%rbp), %rdi
callq 0x29ee0
leaq 0x46d24(%rip), %rdi     # 0x742ca
leaq 0x46900(%rip), %rsi     # 0x73ead
leaq 0x46d40(%rip), %rcx     # 0x742f4
movl $0x2e8e, %edx           # imm = 0x2E8E
callq 0x24390
jmp 0x2d5f6
jmp 0x2d5d0
movq %rax, %rbx
movq -0x38(%rbp), %r14
jmp 0x2d609
movq %rax, %rbx
jmp 0x2d609
movq %rax, %rbx
jmp 0x2d5fd
movq %rax, %rbx
leaq -0xa0(%rbp), %rdi
callq 0x24ad8
jmp 0x2d5eb
jmp 0x2d5f6
movq %rax, %rbx
leaq -0x60(%rbp), %rdi
callq 0x30e5e
jmp 0x2d5f9
movq %rax, %rbx
movq -0x38(%rbp), %r14
leaq -0xf0(%rbp), %rdi
callq 0x45686
movq %r14, %rdi
callq 0x3e066
movq %rbx, %rdi
callq 0x24950
nop