// File: /workspace/github_c_makefile_star2_O1/ccxvii[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 0x3336f(%rip), %rsi     # 0x403f8
testq %rax, %rax
js 0xd0a4
cmpl 0x140(%rbx), %eax
jge 0xd0a4
shlq $0x4, %rax
addq 0x148(%rbx), %rax
movq %rax, %rsi
movq %rbx, %rdi
callq 0x15489
movq %rax, %r14
movq $0x0, (%rsp)
movq %rbx, %rdi
xorl %esi, %esi
callq 0x14e17
testl %eax, %eax
je 0xd31f
movq %r14, %r15
movl (%r14), %eax
movl %eax, %ecx
addl $-0x2, %ecx
cmpl $0x2, %ecx
jae 0xd20d
movq 0x20(%r15), %r15
movq %rbx, %rdi
callq 0x13fbb
movq %rax, %rdi
callq 0x3100
testl %eax, %eax
jne 0xd330
movb $0x66, %cl
movl $0x1, %eax
leaq 0x271fe(%rip), %r12     # 0x34305
movq %rsp, %r14
movq %rax, %r13
movsbl %cl, %edx
movq %rbx, %rdi
movq %r14, %rsi
callq 0xe0bc
movb (%r13,%r12), %cl
incq %r13
movq %r13, %rax
cmpq $0xa, %r13
jne 0xd10a
movq (%r15), %rcx
movb (%rcx), %al
testb %al, %al
je 0xd15c
incq %rcx
movq %rsp, %r14
movq %rcx, %r12
movsbl %al, %edx
movq %rbx, %rdi
movq %r14, %rsi
callq 0xe0bc
movb (%r12), %dl
incq %r12
movq %r12, %rcx
movl %edx, %eax
testb %dl, %dl
jne 0xd13b
movq %rsp, %rsi
movq %rbx, %rdi
movl $0x28, %edx
callq 0xe0bc
cmpl $0x0, 0x18(%r15)
jle 0xd1d6
xorl %eax, %eax
movl %eax, %r12d
movq %rsp, %r14
movl $0x2c, %ebp
testq %r12, %r12
je 0xd192
movq %rbx, %rdi
movq %r14, %rsi
movl %ebp, %edx
callq 0xe0bc
movq 0x40(%r15), %rax
movq (%rax,%r12,8), %rax
movb (%rax), %cl
testb %cl, %cl
je 0xd1c4
incq %rax
movq %rax, %r13
movsbl %cl, %edx
movq %rbx, %rdi
movq %r14, %rsi
callq 0xe0bc
movb (%r13), %dl
incq %r13
movq %r13, %rax
movl %edx, %ecx
testb %dl, %dl
jne 0xd1a3
movq %r12, %rax
incq %rax
movslq 0x18(%r15), %rcx
movq %rax, %r12
cmpq %rcx, %rax
jl 0xd180
movb $0x29, %cl
movl $0x1, %eax
leaq 0x2712b(%rip), %r15     # 0x3430f
movq %rsp, %r14
movq %rax, %r12
movsbl %cl, %edx
movq %rbx, %rdi
movq %r14, %rsi
callq 0xe0bc
movb (%r12,%r15), %cl
incq %r12
movq %r12, %rax
cmpq $0x12, %r12
jne 0xd1e7
jmp 0xd2c3
cmpl $0x4, %eax
jne 0xd301
movq %rbx, %rdi
callq 0x13fbb
movq %rax, %rdi
callq 0x3100
testl %eax, %eax
jne 0xd330
movb $0x66, %cl
movl $0x1, %eax
leaq 0x270c9(%rip), %r12     # 0x34305
movq %rsp, %r14
movq %rax, %r13
movsbl %cl, %edx
movq %rbx, %rdi
movq %r14, %rsi
callq 0xe0bc
movb (%r13,%r12), %cl
incq %r13
movq %r13, %rax
cmpq $0xa, %r13
jne 0xd23f
movq 0x20(%r15), %rcx
movb (%rcx), %al
testb %al, %al
je 0xd291
incq %rcx
movq %rsp, %r14
movq %rcx, %r15
movsbl %al, %edx
movq %rbx, %rdi
movq %r14, %rsi
callq 0xe0bc
movb (%r15), %dl
incq %r15
movq %r15, %rcx
movl %edx, %eax
testb %dl, %dl
jne 0xd271
movb $0x28, %cl
movl $0x1, %eax
leaq 0x27082(%rip), %r15     # 0x34321
movq %rsp, %r14
movq %rax, %r12
movsbl %cl, %edx
movq %rbx, %rdi
movq %r14, %rsi
callq 0xe0bc
movb (%r12,%r15), %cl
incq %r12
movq %r12, %rax
cmpq $0x15, %r12
jne 0xd2a2
movq %rsp, %r14
movq %rbx, %rdi
movq %r14, %rsi
xorl %edx, %edx
callq 0xe0bc
movq (%r14), %r14
leaq 0x8(%r14), %rsi
movq %rbx, %rdi
callq 0x13665
movl 0x8198(%rbx), %eax
testl %eax, %eax
je 0xd342
decl %eax
movl %eax, 0x8198(%rbx)
movq (%rbx), %rdi
movq %r14, %rsi
xorl %edx, %edx
callq *0x10(%rbx)
jmp 0xd310
leaq 0x2702e(%rip), %rsi     # 0x34336
movq %rbx, %rdi
callq 0x67c1
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
leaq 0x26f61(%rip), %rsi     # 0x34287
xorl %eax, %eax
movq %rbx, %rdi
callq 0xcce3
movq (%rbx), %rdi
xorl %edx, %edx
movl %edx, %esi
callq *0x10(%rbx)
movq %rbx, %rdi
callq 0x8ec6
leaq 0x264c0(%rip), %rsi     # 0x33809
xorl %eax, %eax
movq %rbx, %rdi
callq 0xc939