// File: /workspace/github_c_makefile_star2_O3/ArtifexSoftware[P]mujs/./json.c
// Function: fmtstr
static void fmtstr(js_State *J, js_Buffer **sb, const char *s)
{
	static const char *HEX = "0123456789abcdef";
	int i, n;
	Rune c;
	js_putc(J, sb, '"');
	while (*s) {
		n = chartorune(&c, s);
		switch (c) {
		case '"': js_puts(J, sb, "\\\""); break;
		case '\\': js_puts(J, sb, "\\\\"); break;
		case '\b': js_puts(J, sb, "\\b"); break;
		case '\f': js_puts(J, sb, "\\f"); break;
		case '\n': js_puts(J, sb, "\\n"); break;
		case '\r': js_puts(J, sb, "\\r"); break;
		case '\t': js_puts(J, sb, "\\t"); break;
		default:
			if (c < ' ' || (c >= 0xd800 && c <= 0xdfff)) {
				js_putc(J, sb, '\\');
				js_putc(J, sb, 'u');
				js_putc(J, sb, HEX[(c>>12)&15]);
				js_putc(J, sb, HEX[(c>>8)&15]);
				js_putc(J, sb, HEX[(c>>4)&15]);
				js_putc(J, sb, HEX[c&15]);
			} else if (c < 128) {
				js_putc(J, sb, c);
			} else {
				for (i = 0; i < n; ++i)
					js_putc(J, sb, s[i]);
			}
			break;
		}
		s += n;
	}
	js_putc(J, sb, '"');
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdx, %r15
movq %rsi, %rbx
movq %rdi, %r14
movl $0x22, %edx
callq 0xdda1
cmpb $0x0, (%r15)
je 0x233b9
leaq 0x4(%rsp), %rdi
movq %r15, %rsi
callq 0x18239
movl 0x4(%rsp), %r13d
leal -0x8(%r13), %ecx
movl %eax, %r12d
cmpl $0x5, %ecx
ja 0x231a7
leaq 0x8a17(%rip), %rdx      # 0x2bb84
movslq (%rdx,%rcx,4), %rax
addq %rdx, %rax
jmpq *%rax
movb $0x5c, %al
xorl %r13d, %r13d
leaq 0x1(%r13), %rbp
movsbl %al, %edx
movq %r14, %rdi
movq %rbx, %rsi
callq 0xdda1
leaq 0x11ad8(%rip), %rax     # 0x34c6c
movb 0x1(%r13,%rax), %al
movq %rbp, %r13
cmpq $0x2, %rbp
jne 0x2317b
jmp 0x233aa
cmpl $0x22, %r13d
je 0x23348
cmpl $0x5c, %r13d
jne 0x231e8
movb $0x5c, %al
xorl %r13d, %r13d
leaq 0x1(%r13), %rbp
movsbl %al, %edx
movq %r14, %rdi
movq %rbx, %rsi
callq 0xdda1
leaq 0x11a94(%rip), %rax     # 0x34c69
movb 0x1(%r13,%rax), %al
movq %rbp, %r13
cmpq $0x2, %rbp
jne 0x231bc
jmp 0x233aa
cmpl $0x20, %r13d
setge %al
movl %r13d, %ecx
andl $0x7ffff800, %ecx       # imm = 0x7FFFF800
cmpl $0xd800, %ecx           # imm = 0xD800
setne %cl
testb %cl, %al
jne 0x23376
movq %r14, %rdi
movq %rbx, %rsi
movl $0x5c, %edx
callq 0xdda1
movq %r14, %rdi
movq %rbx, %rsi
movl $0x75, %edx
callq 0xdda1
movl %r13d, %eax
shrl $0xc, %eax
andl $0xf, %eax
leaq 0x11a1c(%rip), %rbp     # 0x34c55
movsbl (%rax,%rbp), %edx
movq %r14, %rdi
movq %rbx, %rsi
callq 0xdda1
movl %r13d, %eax
shrl $0x8, %eax
andl $0xf, %eax
movsbl (%rax,%rbp), %edx
movq %r14, %rdi
movq %rbx, %rsi
callq 0xdda1
movl %r13d, %eax
shrl $0x4, %eax
andl $0xf, %eax
movsbl (%rax,%rbp), %edx
movq %r14, %rdi
movq %rbx, %rsi
callq 0xdda1
andl $0xf, %r13d
movsbl (%r13,%rbp), %r13d
jmp 0x2337f
movb $0x5c, %al
xorl %r13d, %r13d
leaq 0x1(%r13), %rbp
movsbl %al, %edx
movq %r14, %rdi
movq %rbx, %rsi
callq 0xdda1
leaq 0x119d3(%rip), %rax     # 0x34c78
movb 0x1(%r13,%rax), %al
movq %rbp, %r13
cmpq $0x2, %rbp
jne 0x2328c
jmp 0x233aa
movb $0x5c, %al
xorl %r13d, %r13d
leaq 0x1(%r13), %rbp
movsbl %al, %edx
movq %r14, %rdi
movq %rbx, %rsi
callq 0xdda1
leaq 0x1199c(%rip), %rax     # 0x34c72
movb 0x1(%r13,%rax), %al
movq %rbp, %r13
cmpq $0x2, %rbp
jne 0x232bd
jmp 0x233aa
movb $0x5c, %al
xorl %r13d, %r13d
leaq 0x1(%r13), %rbp
movsbl %al, %edx
movq %r14, %rdi
movq %rbx, %rsi
callq 0xdda1
leaq 0x11968(%rip), %rax     # 0x34c6f
movb 0x1(%r13,%rax), %al
movq %rbp, %r13
cmpq $0x2, %rbp
jne 0x232ee
jmp 0x233aa
movb $0x5c, %al
xorl %r13d, %r13d
leaq 0x1(%r13), %rbp
movsbl %al, %edx
movq %r14, %rdi
movq %rbx, %rsi
callq 0xdda1
leaq 0x1193d(%rip), %rax     # 0x34c75
movb 0x1(%r13,%rax), %al
movq %rbp, %r13
cmpq $0x2, %rbp
jne 0x2331f
jmp 0x233aa
movb $0x5c, %al
xorl %r13d, %r13d
leaq 0x1(%r13), %rbp
movsbl %al, %edx
movq %r14, %rdi
movq %rbx, %rsi
callq 0xdda1
leaq 0x11900(%rip), %rax     # 0x34c66
movb 0x1(%r13,%rax), %al
movq %rbp, %r13
cmpq $0x2, %rbp
jne 0x2334d
jmp 0x233aa
cmpl $0x80, %r13d
jae 0x2338f
movq %r14, %rdi
movq %rbx, %rsi
movl %r13d, %edx
callq 0xdda1
jmp 0x233aa
xorl %r13d, %r13d
movsbl (%r15,%r13), %edx
movq %r14, %rdi
movq %rbx, %rsi
callq 0xdda1
incq %r13
cmpq %r13, %r12
jne 0x23392
cmpb $0x0, (%r15,%r12)
leaq (%r15,%r12), %r15
jne 0x23148
movq %r14, %rdi
movq %rbx, %rsi
movl $0x22, %edx
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0xdda1