// File: /workspace/github_cpp_makefile_star2_O3/oknenavin[P]cxon/test/../src/cxon/lang/common/cio/variant.hxx
// Function: bool cxon::cio::var::variant_read<cxon::JSON<cxon::test::allow_comments_traits<cxon::json::format_traits>>, boost::variant2::variant<std::nullptr_t>, char const*, cxon::context<cxon::JSON<cxon::test::allow_comments_traits<cxon::json::format_traits>>>>(boost::variant2::variant<std::nullptr_t>&, char const*&, char const*, cxon::context<cxon::JSON<cxon::test::allow_comments_traits<cxon::json::format_traits>>>&)
inline bool variant_read(V& v, II& i, II e, Cx& cx) {
            if (!consume<X>(i, e, cx))
                return false;
            switch (peek(i, e)) {
                case X::map::beg:
                    return imp::variant_read_<X, is_map>(v, i, e, cx);
                case X::list::beg:
                    return imp::variant_read_<X, is_list>(v, i, e, cx);
                case X::string::del:
                    return imp::variant_read_<X, is_string>(v, i, e, cx);
                case '-': case '0': case '1': case '2': case '3': case '4': case '5': case '6': case '7': case '8': case '9': case 'I': case 'N':
                    return imp::variant_read_<X, is_number>(v, i, e, cx);
                case *X::id::pos: case *X::id::neg:
                    return imp::variant_read_<X, is_bool>(v, i, e, cx);
                case *X::id::nil:
                    return imp::variant_read_<X, is_null>(v, i, e, cx);
            }
            return cx/json::read_error::unexpected;
        }

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rcx, %rbx
movq %rdi, %r14
movq (%rsi), %rdi
xorl %ecx, %ecx
leaq 0x12f857(%rip), %rax    # 0x1e5020
cmpq %rdx, %rdi
je 0xb57e1
movzbl (%rdi), %r8d
testb $0x8, (%r8,%rax)
je 0xb57e1
incq %rdi
movq %rdi, (%rsi)
jmp 0xb57c9
cmpq %rdx, %rdi
je 0xb5881
cmpb $0x2f, (%rdi)
jne 0xb5881
leaq 0x1(%rdi), %r8
movq %r8, (%rsi)
cmpq %rdx, %r8
je 0xb5886
movzbl (%r8), %r9d
cmpl $0x2a, %r9d
je 0xb5833
cmpl $0x2f, %r9d
jne 0xb5886
addq $0x2, %rdi
movq %rdi, %r8
movq %r8, (%rsi)
movb $0x1, %cl
cmpq %rdx, %r8
je 0xb586d
cmpb $0xa, (%r8)
movq %r8, %rdi
leaq 0x1(%r8), %r8
jne 0xb581a
jmp 0xb57c9
addq $0x2, %rdi
movq %rdi, (%rsi)
movb $0x1, %cl
cmpq %rdx, %rdi
je 0xb57c9
cmpb $0x2a, (%rdi)
setne %r9b
leaq 0x1(%rdi), %r8
movq %r8, (%rsi)
cmpq %rdx, %r8
sete %r10b
orb %r9b, %r10b
cmpb $0x1, %r10b
je 0xb5865
cmpb $0x2f, (%r8)
je 0xb5875
movq %r8, %rdi
cmpq %rdx, %r8
jne 0xb5841
movq %r8, %rdi
jmp 0xb57c9
addq $0x2, %rdi
movq %rdi, (%rsi)
jmp 0xb57c9
movq %rdi, %r8
jmp 0xb588b
testb $0x1, %cl
je 0xb58b1
cmpq %rdx, %r8
je 0xb58b1
movzbl (%r8), %eax
cmpl $0x65, %eax
jg 0xb58ca
addl $-0x22, %eax
cmpl $0x39, %eax
ja 0xb58b1
movabsq $0x108000ffc800, %rcx   # imm = 0x108000FFC800
btq %rax, %rcx
jae 0xb5903
callq 0x4a9e4
movl $0x1, (%rbx)
movq %rax, 0x8(%rbx)
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
cmpl $0x73, %eax
jg 0xb58f9
cmpl $0x66, %eax
je 0xb58b1
cmpl $0x6e, %eax
jne 0xb58b1
movq %rsp, %rdi
movq %rbx, %rcx
callq 0xb590e
testb %al, %al
je 0xb58c2
movq $0x0, 0x8(%r14)
movl $0x1, (%r14)
jmp 0xb58c2
cmpl $0x74, %eax
je 0xb58b1
cmpl $0x7b, %eax
jmp 0xb58b1
testq %rax, %rax
je 0xb58b1
cmpq $0x39, %rax
jmp 0xb58b1