// File: /workspace/github_c_makefile_star2_O0/Oric4ever[P]lcc65/6502/build/../src/decl.c
// Function: dclparam
static Symbol dclparam(int sclass, char *id, Type ty, Coordinate *pos) {
	Symbol p;

	if ((p = lookup(id, identifiers)) && p->scope == level
	&& (p->defined || p->type == 0 && ty == 0))
		error("duplicate definition for `%s' previously declared at %w\n",
			id, &p->src);
	else if (p == 0 || p->scope < level)
		p = install(id, &identifiers, 0);
	if (ty && isfunc(ty))
		ty = ptr(ty);
	else if (ty && isarray(ty))
		ty = atop(ty);
	if (sclass == 0)
		sclass = AUTO;
	if (sclass == REGISTER && ty && (isvolatile(ty) || isstruct(ty))) {
		warning("register declaration ignored for `%t%s\n", ty,
			stringf(id ? " %s'" : "' parameter", id));
		sclass = AUTO;
	}
	p->sclass = sclass;
	p->src = *pos;
	if (p->type = ty)
		p->defined = 1;
	if (t == '=') {
		error("illegal initialization for parameter `%s'\n", id);
		t = gettok();
		expr1(0);
	}
	return p;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x50, %rsp
movl %edi, -0x4(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq %rcx, -0x20(%rbp)
movq -0x10(%rbp), %rdi
leaq 0x31f26(%rip), %rax     # 0x3b138
movq (%rax), %rsi
callq 0x24670
movq %rax, -0x28(%rbp)
cmpq $0x0, %rax
je 0x9276
movq -0x28(%rbp), %rax
movzwl 0x18(%rax), %eax
leaq 0x37d5d(%rip), %rcx     # 0x40f90
cmpl (%rcx), %eax
jne 0x9276
movq -0x28(%rbp), %rax
movb 0x1b(%rax), %al
andb $0x1, %al
movzbl %al, %eax
cmpl $0x0, %eax
jne 0x925a
movq -0x28(%rbp), %rax
cmpq $0x0, 0x20(%rax)
jne 0x9276
cmpq $0x0, -0x18(%rbp)
jne 0x9276
movq -0x10(%rbp), %rsi
movq -0x28(%rbp), %rdx
addq $0x28, %rdx
leaq 0x264e4(%rip), %rdi     # 0x2f751
movb $0x0, %al
callq 0xd530
jmp 0x92a8
cmpq $0x0, -0x28(%rbp)
je 0x9290
movq -0x28(%rbp), %rax
movzwl 0x18(%rax), %eax
leaq 0x37d04(%rip), %rcx     # 0x40f90
cmpl (%rcx), %eax
jge 0x92a6
movq -0x10(%rbp), %rdi
leaq 0x31e9d(%rip), %rsi     # 0x3b138
xorl %edx, %edx
callq 0x24720
movq %rax, -0x28(%rbp)
jmp 0x92a8
cmpq $0x0, -0x18(%rbp)
je 0x92e6
movq -0x18(%rbp), %rax
cmpl $0xf, (%rax)
jb 0x92c6
movq -0x18(%rbp), %rax
movq 0x10(%rax), %rax
movq %rax, -0x30(%rbp)
jmp 0x92ce
movq -0x18(%rbp), %rax
movq %rax, -0x30(%rbp)
movq -0x30(%rbp), %rax
cmpl $0xb, (%rax)
jne 0x92e6
movq -0x18(%rbp), %rdi
callq 0x27120
movq %rax, -0x18(%rbp)
jmp 0x9324
cmpq $0x0, -0x18(%rbp)
je 0x9322
movq -0x18(%rbp), %rax
cmpl $0xf, (%rax)
jb 0x9304
movq -0x18(%rbp), %rax
movq 0x10(%rax), %rax
movq %rax, -0x38(%rbp)
jmp 0x930c
movq -0x18(%rbp), %rax
movq %rax, -0x38(%rbp)
movq -0x38(%rbp), %rax
cmpl $0xc, (%rax)
jne 0x9322
movq -0x18(%rbp), %rdi
callq 0x27310
movq %rax, -0x18(%rbp)
jmp 0x9324
cmpl $0x0, -0x4(%rbp)
jne 0x9331
movl $0x43, -0x4(%rbp)
cmpl $0x4e, -0x4(%rbp)
jne 0x93f1
cmpq $0x0, -0x18(%rbp)
je 0x93f1
movq -0x18(%rbp), %rax
cmpl $0x10, (%rax)
je 0x93a8
movq -0x18(%rbp), %rax
cmpl $0x1f, (%rax)
je 0x93a8
movq -0x18(%rbp), %rax
cmpl $0xf, (%rax)
jb 0x936f
movq -0x18(%rbp), %rax
movq 0x10(%rax), %rax
movq %rax, -0x40(%rbp)
jmp 0x9377
movq -0x18(%rbp), %rax
movq %rax, -0x40(%rbp)
movq -0x40(%rbp), %rax
cmpl $0x9, (%rax)
je 0x93a8
movq -0x18(%rbp), %rax
cmpl $0xf, (%rax)
jb 0x9397
movq -0x18(%rbp), %rax
movq 0x10(%rax), %rax
movq %rax, -0x48(%rbp)
jmp 0x939f
movq -0x18(%rbp), %rax
movq %rax, -0x48(%rbp)
movq -0x48(%rbp), %rax
cmpl $0xa, (%rax)
jne 0x93f1
movq -0x18(%rbp), %rax
movq %rax, -0x50(%rbp)
movq -0x10(%rbp), %rcx
leaq 0x263fc(%rip), %rdi     # 0x2f7b7
leaq 0x263f0(%rip), %rax     # 0x2f7b2
cmpq $0x0, %rcx
cmovneq %rax, %rdi
movq -0x10(%rbp), %rsi
movb $0x0, %al
callq 0x1afc0
movq -0x50(%rbp), %rsi
movq %rax, %rdx
leaq 0x263a7(%rip), %rdi     # 0x2f78a
movb $0x0, %al
callq 0xdba0
movl $0x43, -0x4(%rbp)
movl -0x4(%rbp), %eax
movb %al, %cl
movq -0x28(%rbp), %rax
movb %cl, 0x1a(%rax)
movq -0x28(%rbp), %rax
movq -0x20(%rbp), %rcx
movq (%rcx), %rdx
movq %rdx, 0x28(%rax)
movq 0x8(%rcx), %rcx
movq %rcx, 0x30(%rax)
movq -0x18(%rbp), %rax
movq -0x28(%rbp), %rcx
movq %rax, 0x20(%rcx)
cmpq $0x0, %rax
je 0x9436
movq -0x28(%rbp), %rax
movb 0x1b(%rax), %cl
andb $-0x2, %cl
orb $0x1, %cl
movb %cl, 0x1b(%rax)
leaq 0x34743(%rip), %rax     # 0x3db80
cmpl $0x3d, (%rax)
jne 0x946b
movq -0x10(%rbp), %rsi
leaq 0x26376(%rip), %rdi     # 0x2f7c3
movb $0x0, %al
callq 0xd530
callq 0x15170
movl %eax, %ecx
leaq 0x3471e(%rip), %rax     # 0x3db80
movl %ecx, (%rax)
xorl %edi, %edi
callq 0xfe00
movq -0x28(%rbp), %rax
addq $0x50, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)