// File: /workspace/github_c_makefile_star2_O3/ArtifexSoftware[P]mujs/./jsfunction.c
// Function: Fp_toString
static void Fp_toString(js_State *J)
{
	js_Object *self = js_toobject(J, 0);
	js_Buffer *sb = NULL;
	int i;

	if (!js_iscallable(J, 0))
		js_typeerror(J, "not a function");

	if (self->type == JS_CFUNCTION || self->type == JS_CSCRIPT) {
		js_Function *F = self->u.f.function;

		if (js_try(J)) {
			js_free(J, sb);
			js_throw(J);
		}

		js_puts(J, &sb, "function ");
		js_puts(J, &sb, F->name);
		js_putc(J, &sb, '(');
		for (i = 0; i < F->numparams; ++i) {
			if (i > 0) js_putc(J, &sb, ',');
			js_puts(J, &sb, F->vartab[i]);
		}
		js_puts(J, &sb, ") { [byte code] }");
		js_putc(J, &sb, 0);

		js_pushstring(J, sb->s);
		js_endtry(J);
		js_free(J, sb);
	} else if (self->type == JS_CCFUNCTION) {
		if (js_try(J)) {
			js_free(J, sb);
			js_throw(J);
		}

		js_puts(J, &sb, "function ");
		js_puts(J, &sb, self->u.c.name);
		js_puts(J, &sb, "() { [native code] }");
		js_putc(J, &sb, 0);

		js_pushstring(J, sb->s);
		js_endtry(J);
		js_free(J, sb);
	} else {
		js_pushliteral(J, "function () { }");
	}
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdi, %rbx
movslq 0x144(%rdi), %rax
leaq 0x33642(%rip), %rsi     # 0x403f8
testq %rax, %rax
js 0xcdd1
cmpl 0x140(%rbx), %eax
jge 0xcdd1
shlq $0x4, %rax
addq 0x148(%rbx), %rax
movq %rax, %rsi
movq %rbx, %rdi
callq 0x14fb2
movq %rax, %r14
movq $0x0, (%rsp)
movq %rbx, %rdi
xorl %esi, %esi
callq 0x14940
testl %eax, %eax
je 0xd04c
movq %r14, %r15
movl (%r14), %eax
movl %eax, %ecx
addl $-0x2, %ecx
cmpl $0x2, %ecx
jae 0xcf3a
movq 0x20(%r15), %r15
movq %rbx, %rdi
callq 0x13b6c
movq %rax, %rdi
callq 0x3100
testl %eax, %eax
jne 0xd05d
movb $0x66, %cl
movl $0x1, %eax
leaq 0x27501(%rip), %r12     # 0x34335
movq %rsp, %r14
movq %rax, %r13
movsbl %cl, %edx
movq %rbx, %rdi
movq %r14, %rsi
callq 0xdda1
movb (%r13,%r12), %cl
incq %r13
movq %r13, %rax
cmpq $0xa, %r13
jne 0xce37
movq (%r15), %rcx
movb (%rcx), %al
testb %al, %al
je 0xce89
incq %rcx
movq %rsp, %r14
movq %rcx, %r12
movsbl %al, %edx
movq %rbx, %rdi
movq %r14, %rsi
callq 0xdda1
movb (%r12), %dl
incq %r12
movq %r12, %rcx
movl %edx, %eax
testb %dl, %dl
jne 0xce68
movq %rsp, %rsi
movq %rbx, %rdi
movl $0x28, %edx
callq 0xdda1
cmpl $0x0, 0x18(%r15)
jle 0xcf03
xorl %eax, %eax
movl %eax, %r12d
movq %rsp, %r14
movl $0x2c, %ebp
testq %r12, %r12
je 0xcebf
movq %rbx, %rdi
movq %r14, %rsi
movl %ebp, %edx
callq 0xdda1
movq 0x40(%r15), %rax
movq (%rax,%r12,8), %rax
movb (%rax), %cl
testb %cl, %cl
je 0xcef1
incq %rax
movq %rax, %r13
movsbl %cl, %edx
movq %rbx, %rdi
movq %r14, %rsi
callq 0xdda1
movb (%r13), %dl
incq %r13
movq %r13, %rax
movl %edx, %ecx
testb %dl, %dl
jne 0xced0
movq %r12, %rax
incq %rax
movslq 0x18(%r15), %rcx
movq %rax, %r12
cmpq %rcx, %rax
jl 0xcead
movb $0x29, %cl
movl $0x1, %eax
leaq 0x2742e(%rip), %r15     # 0x3433f
movq %rsp, %r14
movq %rax, %r12
movsbl %cl, %edx
movq %rbx, %rdi
movq %r14, %rsi
callq 0xdda1
movb (%r12,%r15), %cl
incq %r12
movq %r12, %rax
cmpq $0x12, %r12
jne 0xcf14
jmp 0xcff0
cmpl $0x4, %eax
jne 0xd02e
movq %rbx, %rdi
callq 0x13b6c
movq %rax, %rdi
callq 0x3100
testl %eax, %eax
jne 0xd05d
movb $0x66, %cl
movl $0x1, %eax
leaq 0x273cc(%rip), %r12     # 0x34335
movq %rsp, %r14
movq %rax, %r13
movsbl %cl, %edx
movq %rbx, %rdi
movq %r14, %rsi
callq 0xdda1
movb (%r13,%r12), %cl
incq %r13
movq %r13, %rax
cmpq $0xa, %r13
jne 0xcf6c
movq 0x20(%r15), %rcx
movb (%rcx), %al
testb %al, %al
je 0xcfbe
incq %rcx
movq %rsp, %r14
movq %rcx, %r15
movsbl %al, %edx
movq %rbx, %rdi
movq %r14, %rsi
callq 0xdda1
movb (%r15), %dl
incq %r15
movq %r15, %rcx
movl %edx, %eax
testb %dl, %dl
jne 0xcf9e
movb $0x28, %cl
movl $0x1, %eax
leaq 0x27385(%rip), %r15     # 0x34351
movq %rsp, %r14
movq %rax, %r12
movsbl %cl, %edx
movq %rbx, %rdi
movq %r14, %rsi
callq 0xdda1
movb (%r12,%r15), %cl
incq %r12
movq %r12, %rax
cmpq $0x15, %r12
jne 0xcfcf
movq %rsp, %r14
movq %rbx, %rdi
movq %r14, %rsi
xorl %edx, %edx
callq 0xdda1
movq (%r14), %r14
leaq 0x8(%r14), %rsi
movq %rbx, %rdi
callq 0x13215
movl 0x8198(%rbx), %eax
testl %eax, %eax
je 0xd06f
decl %eax
movl %eax, 0x8198(%rbx)
movq (%rbx), %rdi
movq %r14, %rsi
xorl %edx, %edx
callq *0x10(%rbx)
jmp 0xd03d
leaq 0x27331(%rip), %rsi     # 0x34366
movq %rbx, %rdi
callq 0x670c
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
leaq 0x27264(%rip), %rsi     # 0x342b7
xorl %eax, %eax
movq %rbx, %rdi
callq 0xca10
movq (%rbx), %rdi
xorl %edx, %edx
movl %edx, %esi
callq *0x10(%rbx)
movq %rbx, %rdi
callq 0x8e1b
leaq 0x267c3(%rip), %rsi     # 0x33839
xorl %eax, %eax
movq %rbx, %rdi
callq 0xc666