// File: /workspace/github_c_makefile_star2_O0/mijallen[P]SimpleHTTPServer/lib/libyaml/src/scanner.c
// Function: yaml_parser_scan_tag_uri
static int
yaml_parser_scan_tag_uri(yaml_parser_t *parser, int directive,
        yaml_char_t *head, yaml_mark_t start_mark, yaml_char_t **uri)
{
    size_t length = head ? strlen((char *)head) : 0;
    yaml_string_t string = NULL_STRING;

    if (!STRING_INIT(parser, string, INITIAL_STRING_SIZE)) goto error;

    /* Resize the string to include the head. */

    while ((size_t)(string.end - string.start) <= length) {
        if (!yaml_string_extend(&string.start, &string.pointer, &string.end)) {
            parser->error = YAML_MEMORY_ERROR;
            goto error;
        }
    }

    /*
     * Copy the head if needed.
     *
     * Note that we don't copy the leading '!' character.
     */

    if (length > 1) {
        memcpy(string.start, head+1, length-1);
        string.pointer += length-1;
    }

    /* Scan the tag. */

    if (!CACHE(parser, 1)) goto error;

    /*
     * The set of characters that may appear in URI is as follows:
     *
     *      '0'-'9', 'A'-'Z', 'a'-'z', '_', '-', ';', '/', '?', ':', '@', '&',
     *      '=', '+', '$', ',', '.', '!', '~', '*', '\'', '(', ')', '[', ']',
     *      '%'.
     */

    while (IS_ALPHA(parser->buffer) || CHECK(parser->buffer, ';')
            || CHECK(parser->buffer, '/') || CHECK(parser->buffer, '?')
            || CHECK(parser->buffer, ':') || CHECK(parser->buffer, '@')
            || CHECK(parser->buffer, '&') || CHECK(parser->buffer, '=')
            || CHECK(parser->buffer, '+') || CHECK(parser->buffer, '$')
            || CHECK(parser->buffer, ',') || CHECK(parser->buffer, '.')
            || CHECK(parser->buffer, '!') || CHECK(parser->buffer, '~')
            || CHECK(parser->buffer, '*') || CHECK(parser->buffer, '\'')
            || CHECK(parser->buffer, '(') || CHECK(parser->buffer, ')')
            || CHECK(parser->buffer, '[') || CHECK(parser->buffer, ']')
            || CHECK(parser->buffer, '%'))
    {
        /* Check if it is a URI-escape sequence. */

        if (CHECK(parser->buffer, '%')) {
            if (!STRING_EXTEND(parser, string))
                goto error;

            if (!yaml_parser_scan_uri_escapes(parser,
                        directive, start_mark, &string)) goto error;
        }
        else {
            if (!READ(parser, string)) goto error;
        }

        length ++;
        if (!CACHE(parser, 1)) goto error;
    }

    /* Check if the tag is non-empty. */

    if (!length) {
        if (!STRING_EXTEND(parser, string))
            goto error;

        yaml_parser_set_scanner_error(parser, directive ?
                "while parsing a %TAG directive" : "while parsing a tag",
                start_mark, "did not find expected tag URI");
        goto error;
    }

    *uri = string.start;

    return 1;

error:
    STRING_DEL(parser, string);
    return 0;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x80, %rsp
leaq 0x10(%rbp), %rax
movq %rax, -0x50(%rbp)
movq %rdi, -0x10(%rbp)
movl %esi, -0x14(%rbp)
movq %rdx, -0x20(%rbp)
movq %rcx, -0x28(%rbp)
cmpq $0x0, -0x20(%rbp)
je 0xe498
movq -0x20(%rbp), %rdi
callq 0x20d0
movq %rax, -0x58(%rbp)
jmp 0xe4a0
xorl %eax, %eax
movq %rax, -0x58(%rbp)
jmp 0xe4a0
movq -0x58(%rbp), %rax
movq %rax, -0x30(%rbp)
leaq -0x48(%rbp), %rdi
xorl %esi, %esi
movl $0x18, %edx
callq 0x2120
movl $0x10, %edi
callq 0x2080
movq %rax, -0x48(%rbp)
cmpq $0x0, %rax
je 0xe4f8
movq -0x48(%rbp), %rax
movq %rax, -0x38(%rbp)
movq -0x48(%rbp), %rax
addq $0x10, %rax
movq %rax, -0x40(%rbp)
movq -0x48(%rbp), %rdi
xorl %esi, %esi
movl $0x10, %edx
callq 0x2120
movb $0x1, %al
testb $0x1, %al
jne 0xe50d
jmp 0xe508
movq -0x10(%rbp), %rax
movl $0x1, (%rax)
xorl %eax, %eax
testb $0x1, %al
jne 0xe50d
jmp 0xed25
jmp 0xe50f
movq -0x40(%rbp), %rax
movq -0x48(%rbp), %rcx
subq %rcx, %rax
cmpq -0x30(%rbp), %rax
ja 0xe54f
leaq -0x48(%rbp), %rdi
leaq -0x48(%rbp), %rsi
addq $0x10, %rsi
leaq -0x48(%rbp), %rdx
addq $0x8, %rdx
callq 0x20a0
cmpl $0x0, %eax
jne 0xe54d
movq -0x10(%rbp), %rax
movl $0x1, (%rax)
jmp 0xed25
jmp 0xe50f
cmpq $0x1, -0x30(%rbp)
jbe 0xe57f
movq -0x48(%rbp), %rdi
movq -0x20(%rbp), %rsi
addq $0x1, %rsi
movq -0x30(%rbp), %rdx
subq $0x1, %rdx
callq 0x2180
movq -0x30(%rbp), %rax
subq $0x1, %rax
addq -0x38(%rbp), %rax
movq %rax, -0x38(%rbp)
movq -0x10(%rbp), %rax
cmpq $0x1, 0xa8(%rax)
jb 0xe595
movb $0x1, %al
testb $0x1, %al
jne 0xe5ad
jmp 0xe5a8
movq -0x10(%rbp), %rdi
movl $0x1, %esi
callq 0x2060
cmpl $0x0, %eax
jne 0xe5ad
jmp 0xed25
jmp 0xe5af
movq -0x10(%rbp), %rax
movq 0x98(%rax), %rax
movzbl (%rax), %eax
cmpl $0x30, %eax
jl 0xe5de
movq -0x10(%rbp), %rax
movq 0x98(%rax), %rax
movzbl (%rax), %ecx
movb $0x1, %al
cmpl $0x39, %ecx
movb %al, -0x59(%rbp)
jle 0xe88b
movq -0x10(%rbp), %rax
movq 0x98(%rax), %rax
movzbl (%rax), %eax
cmpl $0x41, %eax
jl 0xe60d
movq -0x10(%rbp), %rax
movq 0x98(%rax), %rax
movzbl (%rax), %ecx
movb $0x1, %al
cmpl $0x5a, %ecx
movb %al, -0x59(%rbp)
jle 0xe88b
movq -0x10(%rbp), %rax
movq 0x98(%rax), %rax
movzbl (%rax), %eax
cmpl $0x61, %eax
jl 0xe63c
movq -0x10(%rbp), %rax
movq 0x98(%rax), %rax
movzbl (%rax), %ecx
movb $0x1, %al
cmpl $0x7a, %ecx
movb %al, -0x59(%rbp)
jle 0xe88b
movq -0x10(%rbp), %rax
movq 0x98(%rax), %rax
movzbl (%rax), %ecx
movb $0x1, %al
cmpl $0x5f, %ecx
movb %al, -0x59(%rbp)
je 0xe88b
movq -0x10(%rbp), %rax
movq 0x98(%rax), %rax
movzbl (%rax), %ecx
movb $0x1, %al
cmpl $0x2d, %ecx
movb %al, -0x59(%rbp)
je 0xe88b
movq -0x10(%rbp), %rax
movq 0x98(%rax), %rax
movzbl (%rax), %ecx
movb $0x1, %al
cmpl $0x3b, %ecx
movb %al, -0x59(%rbp)
je 0xe88b
movq -0x10(%rbp), %rax
movq 0x98(%rax), %rax
movzbl (%rax), %ecx
movb $0x1, %al
cmpl $0x2f, %ecx
movb %al, -0x59(%rbp)
je 0xe88b
movq -0x10(%rbp), %rax
movq 0x98(%rax), %rax
movzbl (%rax), %ecx
movb $0x1, %al
cmpl $0x3f, %ecx
movb %al, -0x59(%rbp)
je 0xe88b
movq -0x10(%rbp), %rax
movq 0x98(%rax), %rax
movzbl (%rax), %ecx
movb $0x1, %al
cmpl $0x3a, %ecx
movb %al, -0x59(%rbp)
je 0xe88b
movq -0x10(%rbp), %rax
movq 0x98(%rax), %rax
movzbl (%rax), %ecx
movb $0x1, %al
cmpl $0x40, %ecx
movb %al, -0x59(%rbp)
je 0xe88b
movq -0x10(%rbp), %rax
movq 0x98(%rax), %rax
movzbl (%rax), %ecx
movb $0x1, %al
cmpl $0x26, %ecx
movb %al, -0x59(%rbp)
je 0xe88b
movq -0x10(%rbp), %rax
movq 0x98(%rax), %rax
movzbl (%rax), %ecx
movb $0x1, %al
cmpl $0x3d, %ecx
movb %al, -0x59(%rbp)
je 0xe88b
movq -0x10(%rbp), %rax
movq 0x98(%rax), %rax
movzbl (%rax), %ecx
movb $0x1, %al
cmpl $0x2b, %ecx
movb %al, -0x59(%rbp)
je 0xe88b
movq -0x10(%rbp), %rax
movq 0x98(%rax), %rax
movzbl (%rax), %ecx
movb $0x1, %al
cmpl $0x24, %ecx
movb %al, -0x59(%rbp)
je 0xe88b
movq -0x10(%rbp), %rax
movq 0x98(%rax), %rax
movzbl (%rax), %ecx
movb $0x1, %al
cmpl $0x2c, %ecx
movb %al, -0x59(%rbp)
je 0xe88b
movq -0x10(%rbp), %rax
movq 0x98(%rax), %rax
movzbl (%rax), %ecx
movb $0x1, %al
cmpl $0x2e, %ecx
movb %al, -0x59(%rbp)
je 0xe88b
movq -0x10(%rbp), %rax
movq 0x98(%rax), %rax
movzbl (%rax), %ecx
movb $0x1, %al
cmpl $0x21, %ecx
movb %al, -0x59(%rbp)
je 0xe88b
movq -0x10(%rbp), %rax
movq 0x98(%rax), %rax
movzbl (%rax), %ecx
movb $0x1, %al
cmpl $0x7e, %ecx
movb %al, -0x59(%rbp)
je 0xe88b
movq -0x10(%rbp), %rax
movq 0x98(%rax), %rax
movzbl (%rax), %ecx
movb $0x1, %al
cmpl $0x2a, %ecx
movb %al, -0x59(%rbp)
je 0xe88b
movq -0x10(%rbp), %rax
movq 0x98(%rax), %rax
movzbl (%rax), %ecx
movb $0x1, %al
cmpl $0x27, %ecx
movb %al, -0x59(%rbp)
je 0xe88b
movq -0x10(%rbp), %rax
movq 0x98(%rax), %rax
movzbl (%rax), %ecx
movb $0x1, %al
cmpl $0x28, %ecx
movb %al, -0x59(%rbp)
je 0xe88b
movq -0x10(%rbp), %rax
movq 0x98(%rax), %rax
movzbl (%rax), %ecx
movb $0x1, %al
cmpl $0x29, %ecx
movb %al, -0x59(%rbp)
je 0xe88b
movq -0x10(%rbp), %rax
movq 0x98(%rax), %rax
movzbl (%rax), %ecx
movb $0x1, %al
cmpl $0x5b, %ecx
movb %al, -0x59(%rbp)
je 0xe88b
movq -0x10(%rbp), %rax
movq 0x98(%rax), %rax
movzbl (%rax), %ecx
movb $0x1, %al
cmpl $0x5d, %ecx
movb %al, -0x59(%rbp)
je 0xe88b
movq -0x10(%rbp), %rax
movq 0x98(%rax), %rax
movzbl (%rax), %eax
cmpl $0x25, %eax
sete %al
movb %al, -0x59(%rbp)
movb -0x59(%rbp), %al
testb $0x1, %al
jne 0xe897
jmp 0xec79
movq -0x10(%rbp), %rax
movq 0x98(%rax), %rax
movzbl (%rax), %eax
cmpl $0x25, %eax
jne 0xe933
movq -0x38(%rbp), %rax
addq $0x5, %rax
cmpq -0x40(%rbp), %rax
jb 0xe8da
leaq -0x48(%rbp), %rdi
leaq -0x48(%rbp), %rsi
addq $0x10, %rsi
leaq -0x48(%rbp), %rdx
addq $0x8, %rdx
callq 0x20a0
cmpl $0x0, %eax
je 0xe8e2
movb $0x1, %al
testb $0x1, %al
jne 0xe8f7
jmp 0xe8f2
movq -0x10(%rbp), %rax
movl $0x1, (%rax)
xorl %eax, %eax
testb $0x1, %al
jne 0xe8f7
jmp 0xed25
movq -0x50(%rbp), %rax
movq -0x10(%rbp), %rdi
movl -0x14(%rbp), %esi
leaq -0x48(%rbp), %rdx
movq (%rax), %rcx
movq %rcx, (%rsp)
movq 0x8(%rax), %rcx
movq %rcx, 0x8(%rsp)
movq 0x10(%rax), %rax
movq %rax, 0x10(%rsp)
callq 0xed60
cmpl $0x0, %eax
jne 0xe92e
jmp 0xed25
jmp 0xec3a
movq -0x38(%rbp), %rax
addq $0x5, %rax
cmpq -0x40(%rbp), %rax
jb 0xe95f
leaq -0x48(%rbp), %rdi
leaq -0x48(%rbp), %rsi
addq $0x10, %rsi
leaq -0x48(%rbp), %rdx
addq $0x8, %rdx
callq 0x20a0
cmpl $0x0, %eax
je 0xe96a
movb $0x1, %al
testb $0x1, %al
jne 0xe97f
jmp 0xec2b
movq -0x10(%rbp), %rax
movl $0x1, (%rax)
xorl %eax, %eax
testb $0x1, %al
jne 0xe97f
jmp 0xec2b
movq -0x10(%rbp), %rax
movq 0x98(%rax), %rax
movzbl (%rax), %eax
andl $0x80, %eax
cmpl $0x0, %eax
jne 0xe9cb
movq -0x10(%rbp), %rcx
movq 0x98(%rcx), %rax
movq %rax, %rdx
addq $0x1, %rdx
movq %rdx, 0x98(%rcx)
movb (%rax), %al
movq -0x38(%rbp), %rcx
movq %rcx, %rdx
addq $0x1, %rdx
movq %rdx, -0x38(%rbp)
movb %al, (%rcx)
movzbl %al, %eax
jmp 0xebe1
movq -0x10(%rbp), %rax
movq 0x98(%rax), %rax
movzbl (%rax), %eax
andl $0xe0, %eax
cmpl $0xc0, %eax
jne 0xea48
movq -0x10(%rbp), %rcx
movq 0x98(%rcx), %rax
movq %rax, %rdx
addq $0x1, %rdx
movq %rdx, 0x98(%rcx)
movb (%rax), %cl
movq -0x38(%rbp), %rax
movq %rax, %rdx
addq $0x1, %rdx
movq %rdx, -0x38(%rbp)
movb %cl, (%rax)
movq -0x10(%rbp), %rcx
movq 0x98(%rcx), %rax
movq %rax, %rdx
addq $0x1, %rdx
movq %rdx, 0x98(%rcx)
movb (%rax), %al
movq -0x38(%rbp), %rcx
movq %rcx, %rdx
addq $0x1, %rdx
movq %rdx, -0x38(%rbp)
movb %al, (%rcx)
movzbl %al, %eax
movl %eax, -0x60(%rbp)
jmp 0xebde
movq -0x10(%rbp), %rax
movq 0x98(%rax), %rax
movzbl (%rax), %eax
andl $0xf0, %eax
cmpl $0xe0, %eax
jne 0xeaf5
movq -0x10(%rbp), %rcx
movq 0x98(%rcx), %rax
movq %rax, %rdx
addq $0x1, %rdx
movq %rdx, 0x98(%rcx)
movb (%rax), %cl
movq -0x38(%rbp), %rax
movq %rax, %rdx
addq $0x1, %rdx
movq %rdx, -0x38(%rbp)
movb %cl, (%rax)
movq -0x10(%rbp), %rcx
movq 0x98(%rcx), %rax
movq %rax, %rdx
addq $0x1, %rdx
movq %rdx, 0x98(%rcx)
movb (%rax), %cl
movq -0x38(%rbp), %rax
movq %rax, %rdx
addq $0x1, %rdx
movq %rdx, -0x38(%rbp)
movb %cl, (%rax)
movq -0x10(%rbp), %rcx
movq 0x98(%rcx), %rax
movq %rax, %rdx
addq $0x1, %rdx
movq %rdx, 0x98(%rcx)
movb (%rax), %al
movq -0x38(%rbp), %rcx
movq %rcx, %rdx
addq $0x1, %rdx
movq %rdx, -0x38(%rbp)
movb %al, (%rcx)
movzbl %al, %eax
movl %eax, -0x64(%rbp)
jmp 0xebd8
movq -0x10(%rbp), %rax
movq 0x98(%rax), %rax
movzbl (%rax), %eax
andl $0xf8, %eax
cmpl $0xf0, %eax
jne 0xebcb
movq -0x10(%rbp), %rcx
movq 0x98(%rcx), %rax
movq %rax, %rdx
addq $0x1, %rdx
movq %rdx, 0x98(%rcx)
movb (%rax), %cl
movq -0x38(%rbp), %rax
movq %rax, %rdx
addq $0x1, %rdx
movq %rdx, -0x38(%rbp)
movb %cl, (%rax)
movq -0x10(%rbp), %rcx
movq 0x98(%rcx), %rax
movq %rax, %rdx
addq $0x1, %rdx
movq %rdx, 0x98(%rcx)
movb (%rax), %cl
movq -0x38(%rbp), %rax
movq %rax, %rdx
addq $0x1, %rdx
movq %rdx, -0x38(%rbp)
movb %cl, (%rax)
movq -0x10(%rbp), %rcx
movq 0x98(%rcx), %rax
movq %rax, %rdx
addq $0x1, %rdx
movq %rdx, 0x98(%rcx)
movb (%rax), %cl
movq -0x38(%rbp), %rax
movq %rax, %rdx
addq $0x1, %rdx
movq %rdx, -0x38(%rbp)
movb %cl, (%rax)
movq -0x10(%rbp), %rcx
movq 0x98(%rcx), %rax
movq %rax, %rdx
addq $0x1, %rdx
movq %rdx, 0x98(%rcx)
movb (%rax), %al
movq -0x38(%rbp), %rcx
movq %rcx, %rdx
addq $0x1, %rdx
movq %rdx, -0x38(%rbp)
movb %al, (%rcx)
movzbl %al, %eax
movl %eax, -0x68(%rbp)
jmp 0xebd2
xorl %eax, %eax
movl %eax, -0x68(%rbp)
jmp 0xebd2
movl -0x68(%rbp), %eax
movl %eax, -0x64(%rbp)
movl -0x64(%rbp), %eax
movl %eax, -0x60(%rbp)
movl -0x60(%rbp), %eax
movq -0x10(%rbp), %rax
movq 0xe0(%rax), %rcx
addq $0x1, %rcx
movq %rcx, 0xe0(%rax)
movq -0x10(%rbp), %rax
movq 0xf0(%rax), %rcx
addq $0x1, %rcx
movq %rcx, 0xf0(%rax)
movq -0x10(%rbp), %rax
movq 0xa8(%rax), %rcx
addq $-0x1, %rcx
movq %rcx, 0xa8(%rax)
movb $0x1, %al
testb $0x1, %al
jne 0xec38
jmp 0xec33
xorl %eax, %eax
testb $0x1, %al
jne 0xec38
jmp 0xec33
jmp 0xed25
jmp 0xec3a
movq -0x30(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x30(%rbp)
movq -0x10(%rbp), %rax
cmpq $0x1, 0xa8(%rax)
jb 0xec5c
movb $0x1, %al
testb $0x1, %al
jne 0xec74
jmp 0xec6f
movq -0x10(%rbp), %rdi
movl $0x1, %esi
callq 0x2060
cmpl $0x0, %eax
jne 0xec74
jmp 0xed25
jmp 0xe5af
cmpq $0x0, -0x30(%rbp)
jne 0xed11
movq -0x38(%rbp), %rax
addq $0x5, %rax
cmpq -0x40(%rbp), %rax
jb 0xecb0
leaq -0x48(%rbp), %rdi
leaq -0x48(%rbp), %rsi
addq $0x10, %rsi
leaq -0x48(%rbp), %rdx
addq $0x8, %rdx
callq 0x20a0
cmpl $0x0, %eax
je 0xecb8
movb $0x1, %al
testb $0x1, %al
jne 0xecca
jmp 0xecc8
movq -0x10(%rbp), %rax
movl $0x1, (%rax)
xorl %eax, %eax
testb $0x1, %al
jne 0xecca
jmp 0xed25
movq -0x50(%rbp), %rax
movq -0x10(%rbp), %rdi
movl -0x14(%rbp), %edx
leaq 0x1d75a(%rip), %rsi     # 0x2c436
leaq 0x1d734(%rip), %rcx     # 0x2c417
cmpl $0x0, %edx
cmovneq %rcx, %rsi
leaq 0x1d759(%rip), %rdx     # 0x2c44a
movq (%rax), %rcx
movq %rcx, (%rsp)
movq 0x8(%rax), %rcx
movq %rcx, 0x8(%rsp)
movq 0x10(%rax), %rax
movq %rax, 0x10(%rsp)
callq 0xb790
jmp 0xed25
movq -0x48(%rbp), %rcx
movq -0x28(%rbp), %rax
movq %rcx, (%rax)
movl $0x1, -0x4(%rbp)
jmp 0xed4d
movq -0x48(%rbp), %rdi
callq 0x2140
movq $0x0, -0x40(%rbp)
movq $0x0, -0x38(%rbp)
movq $0x0, -0x48(%rbp)
movl $0x0, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x80, %rsp
popq %rbp
retq
nopl (%rax)