// File: /workspace/github_c_makefile_star2_O0/azhai[P]mlite/mlite.c
// Function: type_decl
cell type_decl(void) {
	cell	n, t, new;

	Token = scan();
	if (Token != TOK_ID || !consname_p(Attr))
		return error("constructor name expected at", Attr);
	save(Attr);
	Token = scan();
	if (Token != TOK_ID || Attr != S_equal) {
		unsave(1);
		return error("missing '=' after 'type'", NOEXPR);
	}
	Token = scan();
	t = node(NIL, NIL);
	save(t);
	for (;;) {
		if (Token != TOK_ID) {
			unsave(2);
			return error("constructor expected", NOEXPR);
		}
		save(Attr);
		Token = scan();
		if (Token == TOK_LPAREN) {
			Token = scan();
			n = node(NIL, NIL);
			save(n);
			while (Token == TOK_ID || Token == TOK_CONS) {
				if (Token == TOK_CONS)
					Attr = S_cons;
				car(n) = Attr;
				Token = scan();
				if (Token != TOK_COMMA)
					break;
				Token = scan();
				set(cdr(n), node(NIL, NIL));
				n = cdr(n);
			}
			if (Token != TOK_RPAREN) {
				unsave(4);
				return error("missing ')' in constructor",
						NOEXPR);
			}
			Token = scan();
			n = unsave(1);
			n = node(unsave(1), n);
			save(n);
		}
		car(t) = unsave(1);
		if (Token != TOK_PIPE)
			break;
		Token = scan();
		set(cdr(t), node(NIL, NIL));
		t = cdr(t);
	}
	n = unsave(1);
	n = node(unsave(1), n);
	n = node(S_define_type, n);
	return n;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
callq 0xcc90
movl %eax, 0x174ed(%rip)     # 0x286e0
cmpl $0xfffffed1, 0x174e3(%rip) # imm = 0xFFFFFED1
jne 0x11221
movq 0x173f2(%rip), %rax     # 0x285f8
movq 0x173c3(%rip), %rcx     # 0x285d0
movq 0x16f54(%rip), %rdx     # 0x28168
movq (%rcx,%rdx,8), %rcx
movsbl (%rax,%rcx,8), %eax
cmpl $0x3a, %eax
je 0x1123d
movq 0x16f40(%rip), %rsi     # 0x28168
leaq 0xf766(%rip), %rdi      # 0x20995
callq 0x34b0
movq %rax, -0x8(%rbp)
jmp 0x1156d
movq 0x16f24(%rip), %rdi     # 0x28168
movq 0x16eed(%rip), %rsi     # 0x28138
xorl %edx, %edx
callq 0x3780
movq %rax, 0x16edf(%rip)     # 0x28138
callq 0xcc90
movl %eax, 0x1747c(%rip)     # 0x286e0
cmpl $0xfffffed1, 0x17472(%rip) # imm = 0xFFFFFED1
jne 0x11280
movq 0x16ef1(%rip), %rax     # 0x28168
cmpq 0x1748a(%rip), %rax     # 0x28708
je 0x112a6
movl $0x1, %edi
callq 0x3950
leaq 0xf721(%rip), %rdi      # 0x209b2
movq $-0x8, %rsi
callq 0x34b0
movq %rax, -0x8(%rbp)
jmp 0x1156d
callq 0xcc90
movl %eax, 0x1742f(%rip)     # 0x286e0
movq $-0x1, %rsi
xorl %edx, %edx
movq %rsi, %rdi
callq 0x3780
movq %rax, -0x18(%rbp)
movq -0x18(%rbp), %rdi
movq 0x16e67(%rip), %rsi     # 0x28138
xorl %edx, %edx
callq 0x3780
movq %rax, 0x16e59(%rip)     # 0x28138
cmpl $0xfffffed1, 0x173f7(%rip) # imm = 0xFFFFFED1
je 0x11311
movl $0x2, %edi
callq 0x3950
leaq 0xf6cf(%rip), %rdi      # 0x209cb
movq $-0x8, %rsi
callq 0x34b0
movq %rax, -0x8(%rbp)
jmp 0x1156d
movq 0x16e50(%rip), %rdi     # 0x28168
movq 0x16e19(%rip), %rsi     # 0x28138
xorl %edx, %edx
callq 0x3780
movq %rax, 0x16e0b(%rip)     # 0x28138
callq 0xcc90
movl %eax, 0x173a8(%rip)     # 0x286e0
cmpl $-0x68, 0x173a1(%rip)   # 0x286e0
jne 0x114b3
callq 0xcc90
movl %eax, 0x17390(%rip)     # 0x286e0
movq $-0x1, %rsi
xorl %edx, %edx
movq %rsi, %rdi
callq 0x3780
movq %rax, -0x10(%rbp)
movq -0x10(%rbp), %rdi
movq 0x16dc8(%rip), %rsi     # 0x28138
xorl %edx, %edx
callq 0x3780
movq %rax, 0x16dba(%rip)     # 0x28138
movb $0x1, %al
cmpl $0xfffffed1, 0x17356(%rip) # imm = 0xFFFFFED1
movb %al, -0x21(%rbp)
je 0x1139c
cmpl $-0x67, 0x1734a(%rip)   # 0x286e0
sete %al
movb %al, -0x21(%rbp)
movb -0x21(%rbp), %al
testb $0x1, %al
jne 0x113a8
jmp 0x11436
cmpl $-0x67, 0x17331(%rip)   # 0x286e0
jne 0x113bf
movq 0x172e8(%rip), %rax     # 0x286a0
movq %rax, 0x16da9(%rip)     # 0x28168
movq 0x16da2(%rip), %rdx     # 0x28168
movq 0x16db3(%rip), %rax     # 0x28180
movq -0x10(%rbp), %rcx
movq %rdx, (%rax,%rcx,8)
callq 0xcc90
movl %eax, 0x17300(%rip)     # 0x286e0
cmpl $-0x64, 0x172f9(%rip)   # 0x286e0
je 0x113eb
jmp 0x11436
callq 0xcc90
movl %eax, 0x172ea(%rip)     # 0x286e0
movq $-0x1, %rsi
xorl %edx, %edx
movq %rsi, %rdi
callq 0x3780
movq %rax, -0x20(%rbp)
movq -0x20(%rbp), %rdx
movq 0x171ba(%rip), %rax     # 0x285d0
movq -0x10(%rbp), %rcx
movq %rdx, (%rax,%rcx,8)
movq 0x171ab(%rip), %rax     # 0x285d0
movq -0x10(%rbp), %rcx
movq (%rax,%rcx,8), %rax
movq %rax, -0x10(%rbp)
jmp 0x1137e
cmpl $-0x69, 0x172a3(%rip)   # 0x286e0
je 0x11465
movl $0x4, %edi
callq 0x3950
leaq 0xf590(%rip), %rdi      # 0x209e0
movq $-0x8, %rsi
callq 0x34b0
movq %rax, -0x8(%rbp)
jmp 0x1156d
callq 0xcc90
movl %eax, 0x17270(%rip)     # 0x286e0
movl $0x1, %edi
callq 0x3950
movq %rax, -0x10(%rbp)
movl $0x1, %edi
callq 0x3950
movq %rax, %rdi
movq -0x10(%rbp), %rsi
xorl %edx, %edx
callq 0x3780
movq %rax, -0x10(%rbp)
movq -0x10(%rbp), %rdi
movq 0x16c93(%rip), %rsi     # 0x28138
xorl %edx, %edx
callq 0x3780
movq %rax, 0x16c85(%rip)     # 0x28138
movl $0x1, %edi
callq 0x3950
movq %rax, %rdx
movq 0x16cb9(%rip), %rax     # 0x28180
movq -0x18(%rbp), %rcx
movq %rdx, (%rax,%rcx,8)
cmpl $-0x66, 0x1720a(%rip)   # 0x286e0
je 0x114da
jmp 0x11525
callq 0xcc90
movl %eax, 0x171fb(%rip)     # 0x286e0
movq $-0x1, %rsi
xorl %edx, %edx
movq %rsi, %rdi
callq 0x3780
movq %rax, -0x20(%rbp)
movq -0x20(%rbp), %rdx
movq 0x170cb(%rip), %rax     # 0x285d0
movq -0x18(%rbp), %rcx
movq %rdx, (%rax,%rcx,8)
movq 0x170bc(%rip), %rax     # 0x285d0
movq -0x18(%rbp), %rcx
movq (%rax,%rcx,8), %rax
movq %rax, -0x18(%rbp)
jmp 0x112df
movl $0x1, %edi
callq 0x3950
movq %rax, -0x10(%rbp)
movl $0x1, %edi
callq 0x3950
movq %rax, %rdi
movq -0x10(%rbp), %rsi
xorl %edx, %edx
callq 0x3780
movq %rax, -0x10(%rbp)
movq 0x1722a(%rip), %rdi     # 0x28780
movq -0x10(%rbp), %rsi
xorl %edx, %edx
callq 0x3780
movq %rax, -0x10(%rbp)
movq -0x10(%rbp), %rax
movq %rax, -0x8(%rbp)
movq -0x8(%rbp), %rax
addq $0x30, %rsp
popq %rbp
retq
nopw (%rax,%rax)