// File: /workspace/github_c_makefile_star2_O0/markdryan[P]subtilis/frontend/parser_call.c
// Function: prv_process_array_fn_type
static void prv_process_array_fn_type(subtilis_parser_t *p,
				      subtilis_exp_t **poss_args,
				      size_t num_poss_args, const char *name,
				      subtilis_type_t *fn_type,
				      subtilis_error_t *err)
{
	subtilis_type_t fn_type_old;
	size_t i;

	if (fn_type->type == SUBTILIS_TYPE_VOID) {
		subtilis_error_set_bad_proc_name(err, name, p->l->stream->name,
						 p->l->line);
		return;
	}

	if ((num_poss_args != 1) ||
	    (poss_args[0]->type.type != SUBTILIS_TYPE_CONST_INTEGER) ||
	    (poss_args[0]->exp.ir_op.integer < 1) ||
	    (poss_args[0]->exp.ir_op.integer > SUBTILIS_MAX_DIMENSIONS)) {
		subtilis_error_bad_dim(err, "return type", p->l->stream->name,
				       p->l->line);
		return;
	}

	subtilis_type_init_copy(&fn_type_old, fn_type, err);
	if (err->type != SUBTILIS_ERROR_OK)
		return;
	subtilis_type_if_array_of(&fn_type_old, fn_type, err);
	subtilis_type_free(&fn_type_old);
	if (err->type != SUBTILIS_ERROR_OK)
		return;

	fn_type->params.array.num_dims = poss_args[0]->exp.ir_op.integer;
	for (i = 0; i < fn_type->params.array.num_dims; i++)
		fn_type->params.array.dims[i] = SUBTILIS_DYNAMIC_DIMENSION;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x190, %rsp            # imm = 0x190
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq %rcx, -0x20(%rbp)
movq %r8, -0x28(%rbp)
movq %r9, -0x30(%rbp)
movq -0x28(%rbp), %rax
cmpl $0x8, (%rax)
jne 0x1ea63
movq -0x30(%rbp), %rdi
movq -0x20(%rbp), %rdx
movq -0x8(%rbp), %rax
movq (%rax), %rax
movq 0x30(%rax), %r8
movq -0x8(%rbp), %rax
movq (%rax), %rax
movl 0x38(%rax), %r9d
movl $0xb, %esi
leaq 0x8c830(%rip), %rcx     # 0xab276
leaq 0x8bbe3(%rip), %rax     # 0xaa630
movq %rax, (%rsp)
movl $0x120, 0x8(%rsp)       # imm = 0x120
callq 0x156d0
jmp 0x1eb87
cmpq $0x1, -0x18(%rbp)
jne 0x1ea96
movq -0x10(%rbp), %rax
movq (%rax), %rax
cmpl $0x1, (%rax)
jne 0x1ea96
movq -0x10(%rbp), %rax
movq (%rax), %rax
cmpl $0x1, 0x148(%rax)
jl 0x1ea96
movq -0x10(%rbp), %rax
movq (%rax), %rax
cmpl $0xa, 0x148(%rax)
jle 0x1eae0
movq -0x30(%rbp), %rdi
movq -0x8(%rbp), %rax
movq (%rax), %rax
movq 0x30(%rax), %r8
movq -0x8(%rbp), %rax
movq (%rax), %rax
movl 0x38(%rax), %r9d
movl $0x38, %esi
leaq 0x8bb8b(%rip), %rdx     # 0xaa647
leaq 0x8c7b3(%rip), %rcx     # 0xab276
leaq 0x8bb66(%rip), %rax     # 0xaa630
movq %rax, (%rsp)
movl $0x129, 0x8(%rsp)       # imm = 0x129
callq 0x156d0
jmp 0x1eb87
movq -0x28(%rbp), %rsi
movq -0x30(%rbp), %rdx
leaq -0x178(%rbp), %rdi
callq 0x3dec0
movq -0x30(%rbp), %rax
cmpl $0x0, (%rax)
je 0x1eb02
jmp 0x1eb87
movq -0x28(%rbp), %rsi
movq -0x30(%rbp), %rdx
leaq -0x178(%rbp), %rdi
callq 0x479c0
leaq -0x178(%rbp), %rdi
callq 0x3e100
movq -0x30(%rbp), %rax
cmpl $0x0, (%rax)
je 0x1eb2d
jmp 0x1eb87
movq -0x10(%rbp), %rax
movq (%rax), %rax
movl 0x148(%rax), %ecx
movq -0x28(%rbp), %rax
movl %ecx, 0x8(%rax)
movq $0x0, -0x180(%rbp)
movq -0x180(%rbp), %rax
movq -0x28(%rbp), %rcx
movslq 0x8(%rcx), %rcx
cmpq %rcx, %rax
jae 0x1eb87
movq -0x28(%rbp), %rax
movq -0x180(%rbp), %rcx
movl $0xffffffff, 0xc(%rax,%rcx,4) # imm = 0xFFFFFFFF
movq -0x180(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x180(%rbp)
jmp 0x1eb4c
addq $0x190, %rsp            # imm = 0x190
popq %rbp
retq