// File: /workspace/github_c_makefile_star2_O3/lengjingzju[P]json/json.c
// Function: json_parse_key
static int _json_parse_key(json_parse_t *parse_ptr, json_string_t *jkey)
{
    char *str = NULL;
    char end_ch = '\"';

    parse_ptr->skip_blank(parse_ptr);
    _get_parse_ptr(parse_ptr, 0, 2, &str);

    switch (*str) {
    case '\"':
#if JSON_PARSE_SPECIAL_QUOTES
    case '\'':
#endif
        if (unlikely(str[1] == str[0])) {
#if !JSON_PARSE_EMPTY_KEY
            JsonPareseErr("key is empty!");
            goto err;
#else
            _UPDATE_PARSE_OFFSET(2);
#endif
        } else {
            end_ch = *str;
            _UPDATE_PARSE_OFFSET(1);
            if (unlikely(parse_ptr->parse_string(parse_ptr, end_ch, jkey, &parse_ptr->mem->key_mgr) < 0)) {
                goto err;
            }
            _UPDATE_PARSE_OFFSET(1);
        }
        parse_ptr->skip_blank(parse_ptr);
        _get_parse_ptr(parse_ptr, 0, 1, &str);
        if (unlikely(*str != ':')) {
            JsonPareseErr("key is not before ':'");
            goto err;
        }
        _UPDATE_PARSE_OFFSET(1);
        break;

    default:
#if JSON_PARSE_SPECIAL_QUOTES
        if (unlikely(*str == ':')) {
#if !JSON_PARSE_EMPTY_KEY
            JsonPareseErr("key is empty!");
            goto err;
#else
            _UPDATE_PARSE_OFFSET(1);
#endif
        } else {
            end_ch = ':';
            if (unlikely(parse_ptr->parse_string(parse_ptr, end_ch, jkey, &parse_ptr->mem->key_mgr) < 0)) {
                goto err;
            }
            _UPDATE_PARSE_OFFSET(1);

            while (IS_BLANK((unsigned char)jkey->str[jkey->len - 1]))
                --jkey->len;
            jkey->str[jkey->len] = '\0';
        }
        break;
#else
        JsonPareseErr("key is not started with quotes!");
        goto err;
#endif
    }
    return 0;
err:
    return -1;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x30, %rsp
movq %rsi, %rbx
movq %rdi, %r14
leaq 0x8(%rsp), %r15
andq $0x0, (%r15)
callq *0x40(%rdi)
pushq $0x2
popq %rdx
movq %r14, %rdi
xorl %esi, %esi
movq %r15, %rcx
callq 0x7498
movq (%r15), %rax
cmpb $0x22, (%rax)
jne 0x1f04
cmpb $0x22, 0x1(%rax)
je 0x1f91
incq 0x10(%r14)
movq 0x38(%r14), %rcx
addq $0x28, %rcx
pushq $0x22
popq %rsi
movq %r14, %rdi
movq %rbx, %rdx
callq *0x48(%r14)
pushq $-0x1
popq %rbx
testl %eax, %eax
js 0x1f85
incq 0x10(%r14)
movq %r14, %rdi
callq *0x40(%r14)
pushq $0x1
popq %rdx
leaq 0x8(%rsp), %r15
movq %r14, %rdi
xorl %esi, %esi
movq %r15, %rcx
callq 0x7498
movq (%r15), %rax
cmpb $0x3a, (%rax)
jne 0x1fe6
incq 0x10(%r14)
xorl %ebx, %ebx
jmp 0x1f85
movq 0x30(%r14), %rsi
testq %rsi, %rsi
je 0x1f5c
xorps %xmm0, %xmm0
leaq 0x10(%rsp), %rbx
movaps %xmm0, 0x10(%rbx)
addq 0x10(%r14), %rsi
pushq $0x1f
popq %rdx
movq %rbx, %rdi
callq 0x1050
leaq 0x852d(%rip), %rdi      # 0xa45c
leaq 0x8862(%rip), %rsi      # 0xa798
movl $0xa6a, %edx            # imm = 0xA6A
xorl %eax, %eax
callq 0x10c0
leaq 0x8793(%rip), %rdi      # 0xa6dc
leaq 0x886e(%rip), %rsi      # 0xa7be
movq %rbx, %rdx
xorl %eax, %eax
callq 0x10c0
jmp 0x1f82
leaq 0x84f9(%rip), %rdi      # 0xa45c
leaq 0x882e(%rip), %rsi      # 0xa798
movl $0xa6a, %edx            # imm = 0xA6A
xorl %eax, %eax
callq 0x10c0
leaq 0x8841(%rip), %rdi      # 0xa7be
callq 0x1060
pushq $-0x1
popq %rbx
movl %ebx, %eax
addq $0x30, %rsp
popq %rbx
popq %r14
popq %r15
retq
movq 0x30(%r14), %rsi
testq %rsi, %rsi
je 0x2042
xorps %xmm0, %xmm0
leaq 0x10(%rsp), %rbx
movaps %xmm0, 0x10(%rbx)
addq 0x10(%r14), %rsi
pushq $0x1f
popq %rdx
movq %rbx, %rdi
callq 0x1050
leaq 0x849c(%rip), %rdi      # 0xa45c
leaq 0x87d1(%rip), %rsi      # 0xa798
movl $0xa3e, %edx            # imm = 0xA3E
xorl %eax, %eax
callq 0x10c0
leaq 0x8702(%rip), %rdi      # 0xa6dc
leaq 0x894d(%rip), %rsi      # 0xa92e
jmp 0x1f50
movq 0x30(%r14), %rsi
testq %rsi, %rsi
je 0x2068
xorps %xmm0, %xmm0
leaq 0x10(%rsp), %r15
movaps %xmm0, 0x10(%r15)
addq 0x10(%r14), %rsi
pushq $0x1f
popq %rdx
movq %r15, %rdi
callq 0x1050
leaq 0x844a(%rip), %rdi      # 0xa45c
leaq 0x877f(%rip), %rsi      # 0xa798
movl $0xa4e, %edx            # imm = 0xA4E
xorl %eax, %eax
callq 0x10c0
leaq 0x86b0(%rip), %rdi      # 0xa6dc
leaq 0x8775(%rip), %rsi      # 0xa7a8
movq %r15, %rdx
xorl %eax, %eax
callq 0x10c0
jmp 0x1f85
leaq 0x8413(%rip), %rdi      # 0xa45c
leaq 0x8748(%rip), %rsi      # 0xa798
movl $0xa3e, %edx            # imm = 0xA3E
xorl %eax, %eax
callq 0x10c0
leaq 0x88cb(%rip), %rdi      # 0xa92e
jmp 0x1f7d
leaq 0x83ed(%rip), %rdi      # 0xa45c
leaq 0x8722(%rip), %rsi      # 0xa798
movl $0xa4e, %edx            # imm = 0xA4E
xorl %eax, %eax
callq 0x10c0
leaq 0x871f(%rip), %rdi      # 0xa7a8
callq 0x1060
jmp 0x1f85