// File: /workspace/github_c_makefile_star2_O2/ryvnf[P]czc/lex.c
// Function: esc_char
int esc_char(int quote, FILE *fp)
{
    int c;
    while ((c = lex_getc()) != EOF) {
        if (c == '\n') {
            fatal(loc_new(lex_filepath, linenr), "missing terminating %c",
                    quote);
            return EOF;
        }
        if (c == quote) {
            return EOF;
        }

        if (c == '\\') {
            c = lex_getc();
            if (c == 'x') {
                int res = 0;
                if (hexdigit(&res, c = lex_getc()) < 0) {
                    lex_ungetc(c);
                    fatal(loc_new(lex_filepath, linenr),
                            "missing hex digit after \\x");
                    return 0;
                }
                if (hexdigit(&res, c = lex_getc()) < 0) {
                    lex_ungetc(c);
                }
                return res;
            }

            if (c >= '0' && c <= '7') {
                int res = 0;
                octdigit(&res, c);
                for (int i = 0; i < 2; i++) {
                    if (octdigit(&res, c = lex_getc()) < 0) {
                        lex_ungetc(c);
                        break;
                    }
                }
                return res;
            }

            switch (c) {
                case 'a': return '\n';
                case 'b': return '\b';
                case 'f': return '\f';
                case 'n': return '\n';
                case 't': return '\t';
                case 'v': return '\v';
                case '\\':
                case '"':
                case '\'':
                          return c;
            }

            fprintf(stderr, "unknown escape \\%c\n", c);
            return c;
        }

        return c;
    }
    return EOF;
}

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
subq $0x10, %rsp
movl %edi, %ebp
callq 0x7698
movl %eax, %ebx
cmpl $-0x1, %eax
je 0x77f8
cmpl $0xa, %ebx
je 0x7803
cmpl %ebp, %ebx
jne 0x76f8
pushq $-0x1
popq %rbx
jmp 0x77f8
cmpl $0x5c, %ebx
jne 0x77f8
callq 0x7698
cmpl $0x78, %eax
jne 0x7754
leaq 0xc(%rsp), %r14
andl $0x0, (%r14)
callq 0x7698
movl %eax, %ebx
movq %r14, %rdi
movl %eax, %esi
callq 0x7641
testl %eax, %eax
js 0x7828
callq 0x7698
movl %eax, %ebx
leaq 0xc(%rsp), %rdi
movl %eax, %esi
callq 0x7641
testl %eax, %eax
jns 0x774b
movl %ebx, %edi
callq 0x76b2
movl 0xc(%rsp), %ebx
jmp 0x77f8
movl %eax, %ebp
andl $-0x8, %eax
cmpl $0x30, %eax
jne 0x7790
addl $-0x30, %ebp
pushq $0x3
popq %r14
movl %ebp, %ebx
decl %r14d
je 0x77f8
callq 0x7698
movl %eax, %ecx
andl $-0x8, %ecx
cmpl $0x30, %ecx
jne 0x7787
leal (%rax,%rbx,8), %ebx
addl $-0x30, %ebx
jns 0x7767
movl %eax, %edi
callq 0x76b2
jmp 0x77f8
cmpl $0x22, %ebp
je 0x77f6
cmpl $0x27, %ebp
je 0x77f6
cmpl $0x5c, %ebp
je 0x77f6
pushq $0xa
popq %rbx
cmpl $0x61, %ebp
je 0x77f8
cmpl $0x76, %ebp
je 0x77c7
cmpl $0x66, %ebp
je 0x77ce
cmpl $0x6e, %ebp
je 0x77f8
cmpl $0x74, %ebp
je 0x77d5
cmpl $0x62, %ebp
jne 0x77dc
pushq $0x8
jmp 0x76f2
pushq $0xb
jmp 0x76f2
pushq $0xc
jmp 0x76f2
pushq $0x9
jmp 0x76f2
movq 0xa815(%rip), %rax      # 0x11ff8
movq (%rax), %rdi
leaq 0x4cbd(%rip), %rsi      # 0xc4aa
movl %ebp, %edx
xorl %eax, %eax
callq 0x2130
movl %ebp, %ebx
movl %ebx, %eax
addq $0x10, %rsp
popq %rbx
popq %r14
popq %rbp
retq
movq 0xb5a6(%rip), %rdi      # 0x12db0
movl 0xb590(%rip), %esi      # 0x12da0
callq 0x8018
leaq 0x4c5c(%rip), %rsi      # 0xc478
movq %rax, %rdi
movl %ebp, %edx
xorl %eax, %eax
callq 0x4a05
movl %ebx, %edi
callq 0x76b2
movq 0xb57a(%rip), %rdi      # 0x12db0
movl 0xb564(%rip), %esi      # 0x12da0
callq 0x8018
leaq 0x4c47(%rip), %rsi      # 0xc48f
movq %rax, %rdi
xorl %eax, %eax
callq 0x4a05