// File: /workspace/github_c_makefile_star2_O0/michaelforney[P]cproc/decl.c
// Function: structdecl
static void
structdecl(struct scope *s, struct structbuilder *b)
{
	struct qualtype base, mt;
	char *name;
	unsigned long long width;
	int align;

	if (staticassert(s))
		return;
	attr(NULL, 0);
	base = declspecs(s, NULL, NULL, &align);
	if (!base.type)
		error(&tok.loc, "no type in struct member declaration");
	if (tok.kind == TSEMICOLON) {
		if ((base.type->kind != TYPESTRUCT && base.type->kind != TYPEUNION) || base.type->u.structunion.tag)
			error(&tok.loc, "struct declaration must declare at least one member");
		next();
		addmember(b, base, NULL, align, -1);
		return;
	}
	for (;;) {
		if (consume(TCOLON)) {
			width = intconstexpr(s, false);
			addmember(b, base, NULL, 0, width);
		} else {
			mt = declarator(s, base, &name, NULL, false);
			width = consume(TCOLON) ? intconstexpr(s, false) : -1;
			addmember(b, mt, name, align, width);
		}
		if (tok.kind == TSEMICOLON)
			break;
		expect(TCOMMA, "or ';' after declarator");
	}
	next();
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0xb0, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq -0x8(%rbp), %rdi
callq 0x4f10
testb $0x1, %al
jne 0x6152
jmp 0x6157
jmp 0x6372
xorl %eax, %eax
movl %eax, %edi
xorl %esi, %esi
callq 0x3360
movq -0x8(%rbp), %rsi
leaq -0x70(%rbp), %rdi
xorl %eax, %eax
movl %eax, %ecx
leaq -0x54(%rbp), %r8
movq %rcx, %rdx
callq 0x3a30
movq -0x70(%rbp), %rax
movq %rax, -0x28(%rbp)
movq -0x68(%rbp), %rax
movq %rax, -0x20(%rbp)
movq -0x60(%rbp), %rax
movq %rax, -0x18(%rbp)
cmpq $0x0, -0x28(%rbp)
jne 0x61b2
leaq 0x1c008(%rip), %rdi     # 0x221a8
addq $0x8, %rdi
leaq 0x12936(%rip), %rsi     # 0x18ae1
movb $0x0, %al
callq 0x11190
leaq 0x1bfef(%rip), %rax     # 0x221a8
cmpl $0x61, (%rax)
jne 0x6232
movq -0x28(%rbp), %rax
cmpl $0xf, (%rax)
je 0x61d0
movq -0x28(%rbp), %rax
cmpl $0x10, (%rax)
jne 0x61db
movq -0x28(%rbp), %rax
cmpq $0x0, 0x40(%rax)
je 0x61f4
leaq 0x1bfc6(%rip), %rdi     # 0x221a8
addq $0x8, %rdi
leaq 0x12919(%rip), %rsi     # 0x18b06
movb $0x0, %al
callq 0x11190
callq 0xd540
movq -0x10(%rbp), %rdi
movl -0x54(%rbp), %edx
leaq -0x28(%rbp), %rax
xorl %ecx, %ecx
movl %ecx, %esi
movq $-0x1, %rcx
movq (%rax), %r8
movq %r8, (%rsp)
movq 0x8(%rax), %r8
movq %r8, 0x8(%rsp)
movq 0x10(%rax), %rax
movq %rax, 0x10(%rsp)
callq 0x6380
jmp 0x6372
jmp 0x6234
movl $0x5f, %edi
callq 0xd910
testb $0x1, %al
jne 0x6244
jmp 0x6288
movq -0x8(%rbp), %rdi
xorl %esi, %esi
callq 0x90c0
movq %rax, -0x50(%rbp)
movq -0x10(%rbp), %rdi
movq -0x50(%rbp), %rcx
leaq -0x28(%rbp), %rax
xorl %edx, %edx
movl %edx, %esi
xorl %edx, %edx
movq (%rax), %r8
movq %r8, (%rsp)
movq 0x8(%rax), %r8
movq %r8, 0x8(%rsp)
movq 0x10(%rax), %rax
movq %rax, 0x10(%rsp)
callq 0x6380
jmp 0x6349
movq -0x8(%rbp), %rsi
leaq -0x88(%rbp), %rdi
leaq -0x28(%rbp), %rax
leaq -0x48(%rbp), %rdx
xorl %ecx, %ecx
xorl %r8d, %r8d
movq (%rax), %r9
movq %r9, (%rsp)
movq 0x8(%rax), %r9
movq %r9, 0x8(%rsp)
movq 0x10(%rax), %rax
movq %rax, 0x10(%rsp)
callq 0x42f0
movq -0x88(%rbp), %rax
movq %rax, -0x40(%rbp)
movq -0x80(%rbp), %rax
movq %rax, -0x38(%rbp)
movq -0x78(%rbp), %rax
movq %rax, -0x30(%rbp)
movl $0x5f, %edi
callq 0xd910
testb $0x1, %al
jne 0x62e9
jmp 0x62fd
movq -0x8(%rbp), %rdi
xorl %esi, %esi
callq 0x90c0
movq %rax, -0x90(%rbp)
jmp 0x630d
movq $-0x1, %rax
movq %rax, -0x90(%rbp)
jmp 0x630d
movq -0x90(%rbp), %rax
movq %rax, -0x50(%rbp)
movq -0x10(%rbp), %rdi
movq -0x48(%rbp), %rsi
movl -0x54(%rbp), %edx
movq -0x50(%rbp), %rcx
leaq -0x40(%rbp), %rax
movq (%rax), %r8
movq %r8, (%rsp)
movq 0x8(%rax), %r8
movq %r8, 0x8(%rsp)
movq 0x10(%rax), %rax
movq %rax, 0x10(%rsp)
callq 0x6380
leaq 0x1be58(%rip), %rax     # 0x221a8
cmpl $0x61, (%rax)
jne 0x6357
jmp 0x636d
movl $0x6e, %edi
leaq 0x12325(%rip), %rsi     # 0x18688
callq 0xd8d0
jmp 0x6234
callq 0xd540
addq $0xb0, %rsp
popq %rbp
retq
nopl (%rax,%rax)