// File: /workspace/github_c_makefile_star2_O3/MaoKo[P]FGFX/fgfp/src/cfg.c
// Function: cfg_alias_list
int
cfg_alias_list(cfg_t* cfg) {
	if (peek_token(cfg->lex) == T_RBRACE)
		{ return (DONE); }
	else if (advance_token(cfg->lex) == T_LPAREN) {
		if (advance_token(cfg->lex) != T_TERMINAL) {
			errorf(CURRENT_LINE(cfg->lex),
						"Missing an token identifier in the $ALIAS section.");
			return (ERROR);
		}

		symbol_t* alias_ter = add_symbol_cfg(cfg,
										T_TERMINAL, C_LEXEME(cfg->lex));

		if (advance_token(cfg->lex) != T_BARROW) {
			errorf(CURRENT_LINE(cfg->lex),
						"Missing a => in the $ALIAS section.");
			return (ERROR);
		}
		else if (alias_literal_list(cfg, alias_ter) == ERROR)
			{ return (ERROR); }
		else if (advance_token(cfg->lex) != T_RPAREN) {
			errorf(CURRENT_LINE(cfg->lex),
						"Missing a close paren in the $ALIAS section.");
			return (ERROR);
		}
		else if (peek_token(cfg->lex) == T_COMMA) {
			advance_token(cfg->lex);
			return (cfg_alias_list(cfg));
		}
	}
	else {
		errorf(CURRENT_LINE(cfg->lex),
						"Missing an open paren in the $ALIAS section.");
		return (ERROR);
	}
	return (DONE);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movq %rdi, %r14
movq 0x20(%rdi), %rdi
callq 0x387a
xorl %ebx, %ebx
cmpl $0x33, %eax
je 0x4d45
movq 0x20(%r14), %rdi
callq 0x32ce
movq 0x20(%r14), %rdi
cmpq $0x34, %rax
jne 0x4cf6
callq 0x32ce
movq 0x20(%r14), %rcx
cmpq $0x2d, %rax
jne 0x4d03
movq 0x10(%rcx), %rax
movq (%rax), %rdx
movq %r14, %rdi
movl $0x2d, %esi
callq 0x459f
movq %rax, %r15
movq 0x20(%r14), %rdi
callq 0x32ce
movq 0x20(%r14), %rdi
cmpq $0x2f, %rax
jne 0x4d10
callq 0x387a
cmpl $0x28, %eax
jne 0x4d1d
movq (%r15), %r12
movq 0x20(%r14), %rdi
callq 0x387a
cmpl $0x28, %eax
jne 0x4c86
movq 0x20(%r14), %rdi
callq 0x32ce
movq 0x20(%r14), %rax
movq 0x10(%rax), %rax
movq (%rax), %rdx
movq %r14, %rdi
movl $0x28, %esi
callq 0x459f
cmpl $-0x1, 0x18(%rax)
jne 0x4cc2
movq 0x20(%r15), %rdx
movq 0x20(%rax), %rcx
testq %rdx, %rdx
je 0x4c55
testq %rcx, %rcx
je 0x4c55
cmpq %rcx, %rdx
jne 0x4cda
movb $0x1, 0xc(%rax)
movl %r12d, 0x18(%rax)
testq %rcx, %rcx
je 0x4c6a
movb $0x1, 0x1c(%rax)
movq %rcx, 0x20(%r15)
movq 0x20(%r14), %rdi
callq 0x387a
cmpl $0x31, %eax
jne 0x4c01
movq 0x20(%r14), %rdi
callq 0x32ce
jmp 0x4c01
movq 0x20(%r14), %rdi
callq 0x32ce
movq 0x20(%r14), %rdi
cmpq $0x35, %rax
jne 0x4d2e
callq 0x387a
cmpl $0x31, %eax
jne 0x4d45
movq 0x20(%r14), %rdi
callq 0x32ce
movq 0x20(%r14), %rdi
callq 0x387a
jmp 0x4b8f
movq 0x20(%r14), %rax
movslq 0x28(%rax), %rdi
movq 0x10(%rax), %rax
movq (%rax), %rdx
leaq 0x55ab(%rip), %rsi      # 0xa283
jmp 0x4ced
movq 0x20(%r14), %rax
movslq 0x28(%rax), %rdi
movq 0x10(%r15), %rdx
leaq 0x55ae(%rip), %rsi      # 0xa29b
xorl %eax, %eax
callq 0x3f24
jmp 0x4d40
movslq 0x28(%rdi), %rdi
leaq 0x551f(%rip), %rsi      # 0xa220
jmp 0x4d39
movslq 0x28(%rcx), %rdi
leaq 0x548e(%rip), %rsi      # 0xa19c
jmp 0x4d39
movslq 0x28(%rdi), %rdi
leaq 0x54b4(%rip), %rsi      # 0xa1cf
jmp 0x4d39
movq 0x20(%r14), %rax
movslq 0x28(%rax), %rdi
leaq 0x5521(%rip), %rsi      # 0xa24d
jmp 0x4d39
movslq 0x28(%rdi), %rdi
leaq 0x54ba(%rip), %rsi      # 0xa1f3
xorl %eax, %eax
callq 0x3f24
movl $0xffffffff, %ebx       # imm = 0xFFFFFFFF
movl %ebx, %eax
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq