// File: /workspace/github_c_makefile_star2_O1/ccxvii[P]mujs/./regexp.c
// Function: nextrune
static int nextrune(struct cstate *g)
{
	if (!*g->source) {
		g->yychar = EOF;
		return 0;
	}
	g->source += chartorune(&g->yychar, g->source);
	if (g->yychar == '\\') {
		if (!*g->source)
			die(g, "unterminated escape sequence");
		g->source += chartorune(&g->yychar, g->source);
		switch (g->yychar) {
		case 'f': g->yychar = '\f'; return 0;
		case 'n': g->yychar = '\n'; return 0;
		case 'r': g->yychar = '\r'; return 0;
		case 't': g->yychar = '\t'; return 0;
		case 'v': g->yychar = '\v'; return 0;
		case 'c':
			if (!g->source[0])
				die(g, "unterminated escape sequence");
			g->yychar = (*g->source++) & 31;
			return 0;
		case 'x':
			if (!g->source[0] || !g->source[1])
				die(g, "unterminated escape sequence");
			g->yychar = hex(g, *g->source++) << 4;
			g->yychar += hex(g, *g->source++);
			if (g->yychar == 0) {
				g->yychar = '0';
				return 1;
			}
			return 1;
		case 'u':
			if (!g->source[0] || !g->source[1] || !g->source[2] || !g->source[3])
				die(g, "unterminated escape sequence");
			g->yychar = hex(g, *g->source++) << 12;
			g->yychar += hex(g, *g->source++) << 8;
			g->yychar += hex(g, *g->source++) << 4;
			g->yychar += hex(g, *g->source++);
			if (g->yychar == 0) {
				g->yychar = '0';
				return 1;
			}
			return 1;
		case 0:
			g->yychar = '0';
			return 1;
		}
		if (strchr(ESCAPES, g->yychar))
			return 1;
		if (isunicodeletter(g->yychar) || g->yychar == '_') /* check identity escape */
			die(g, "invalid escape character");
		return 0;
	}
	return 0;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq 0x18(%rdi), %rsi
leaq 0xac(%rdi), %r14
cmpb $0x0, (%rsi)
je 0x2a02e
movq %rdi, %rbx
movq %r14, %rdi
callq 0x18750
movl %eax, %esi
addq 0x18(%rbx), %rsi
movq %rsi, 0x18(%rbx)
cmpl $0x5c, 0xac(%rbx)
jne 0x2a0a8
cmpb $0x0, (%rsi)
je 0x2a1d0
movq %r14, %rdi
callq 0x18750
movl %eax, %ecx
addq 0x18(%rbx), %rcx
movq %rcx, 0x18(%rbx)
movl 0xac(%rbx), %r15d
xorl %eax, %eax
cmpl $0x6d, %r15d
jle 0x2a03a
leal -0x6e(%r15), %edx
cmpl $0xa, %edx
ja 0x2a058
leaq 0x1dfa(%rip), %rsi      # 0x2be18
movslq (%rsi,%rdx,4), %rdx
addq %rsi, %rdx
jmpq *%rdx
movl $0xa, %ecx
jmp 0x2a035
xorl %eax, %eax
movl $0xffffffff, %ecx       # imm = 0xFFFFFFFF
movl %ecx, (%r14)
jmp 0x2a0aa
testl %r15d, %r15d
je 0x2a1a9
cmpl $0x63, %r15d
je 0x2a1b8
movl $0xc, %ecx
cmpl $0x66, %r15d
je 0x2a035
leaq 0xb1e8(%rip), %rdi      # 0x35247
movl $0x22, %edx
movl %r15d, %esi
callq 0x30c0
movq %rax, %rcx
movl $0x1, %eax
testq %rcx, %rcx
jne 0x2a0aa
movl %r15d, %ecx
andl $-0x21, %ecx
addl $-0x41, %ecx
movb $0x1, %al
cmpl $0x1a, %ecx
jb 0x2a096
movl %r15d, %edi
callq 0x1ca5e
testl %eax, %eax
setne %al
cmpl $0x5f, %r15d
je 0x2a1f2
testb %al, %al
jne 0x2a1f2
xorl %eax, %eax
popq %rbx
popq %r14
popq %r15
retq
movl $0xb, %ecx
jmp 0x2a035
movl $0x9, %ecx
jmp 0x2a035
cmpb $0x0, (%rcx)
je 0x2a1d0
cmpb $0x0, 0x1(%rcx)
je 0x2a1d0
cmpb $0x0, 0x2(%rcx)
je 0x2a1d0
cmpb $0x0, 0x3(%rcx)
je 0x2a1d0
leaq 0x1(%rcx), %rax
movq %rax, 0x18(%rbx)
movsbl (%rcx), %esi
movq %rbx, %rdi
callq 0x2a2fb
shll $0xc, %eax
movl %eax, 0xac(%rbx)
movq 0x18(%rbx), %rax
leaq 0x1(%rax), %rcx
movq %rcx, 0x18(%rbx)
movsbl (%rax), %esi
movq %rbx, %rdi
callq 0x2a2fb
shll $0x8, %eax
addl %eax, 0xac(%rbx)
movq 0x18(%rbx), %rax
leaq 0x1(%rax), %rcx
movq %rcx, 0x18(%rbx)
movsbl (%rax), %esi
movq %rbx, %rdi
callq 0x2a2fb
shll $0x4, %eax
addl %eax, 0xac(%rbx)
jmp 0x2a17a
movl $0xd, %ecx
jmp 0x2a035
cmpb $0x0, (%rcx)
je 0x2a1d0
cmpb $0x0, 0x1(%rcx)
je 0x2a1d0
leaq 0x1(%rcx), %rax
movq %rax, 0x18(%rbx)
movsbl (%rcx), %esi
movq %rbx, %rdi
callq 0x2a2fb
shll $0x4, %eax
movl %eax, 0xac(%rbx)
movq 0x18(%rbx), %rax
leaq 0x1(%rax), %rcx
movq %rcx, 0x18(%rbx)
movsbl (%rax), %esi
movq %rbx, %rdi
callq 0x2a2fb
addl 0xac(%rbx), %eax
movl $0x30, %ecx
cmovnel %eax, %ecx
movl $0x1, %eax
jmp 0x2a035
movl $0x1, %eax
movl $0x30, %ecx
jmp 0x2a035
cmpb $0x0, (%rcx)
je 0x2a1d0
leaq 0x1(%rcx), %rdx
movq %rdx, 0x18(%rbx)
movzbl (%rcx), %ecx
andl $0x1f, %ecx
jmp 0x2a035
leaq 0xa6b2(%rip), %rax      # 0x34889
movq %rax, 0xc0(%rbx)
addq $0xc8, %rbx
movq %rbx, %rdi
movl $0x1, %esi
callq 0x3320
leaq 0xb070(%rip), %rax      # 0x35269
jmp 0x2a1d7