// File: /workspace/github_cpp_makefile_star2_O1/nataly-enne[P]pet-fera/pet_fera_remover.cpp
// Function: remover_animal(std::map<int, ANFIBIO_NATIVO, std::less<int>, std::allocator<std::pair<int const, ANFIBIO_NATIVO>>>&, std::map<int, ANFIBIO_EXOTICO, std::less<int>, std::allocator<std::pair<int const, ANFIBIO_EXOTICO>>>&, std::map<int, MAMIFERO_NATIVO, std::less<int>, std::allocator<std::pair<int const, MAMIFERO_NATIVO>>>&, std::map<int, MAMIFERO_EXOTICO, std::less<int>, std::allocator<std::pair<int const, MAMIFERO_EXOTICO>>>&, std::map<int, REPTIL_NATIVO, std::less<int>, std::allocator<std::pair<int const, REPTIL_NATIVO>>>&, std::map<int, REPTIL_EXOTICO, std::less<int>, std::allocator<std::pair<int const, REPTIL_EXOTICO>>>&, std::map<int, AVE_NATIVO, std::less<int>, std::allocator<std::pair<int const, AVE_NATIVO>>>&, std::map<int, AVE_EXOTICO, std::less<int>, std::allocator<std::pair<int const, AVE_EXOTICO>>>&)
void remover_animal(map <int, ANFIBIO_NATIVO> &anfibios_nat, map <int, ANFIBIO_EXOTICO> &anfibios_ex, map <int, MAMIFERO_NATIVO> &mamiferos_nat, map <int, MAMIFERO_EXOTICO> &mamiferos_ex, map <int, REPTIL_NATIVO> &repteis_nat, map <int, REPTIL_EXOTICO> &repteis_ex, map <int, AVE_NATIVO> &aves_nat, map <int, AVE_EXOTICO> &aves_ex){
	char tipo_animal;
	char resp, op = 'n';

	do{  
		cout << "Qual animal deseja remover? \n a - anfíbio\n m - mamífero \n r - reptil \n v - ave" << endl;
		cin >> tipo_animal;
		if(tipo_animal != 'a' && tipo_animal != 'm' && tipo_animal != 'r' && tipo_animal != 'v' ){
			cout << "Opção inválida!! Tente novamente!\n" << endl;
			cout << endl;
			cout << "Deseja sair? s/n" << endl;
			cin >> resp;
			if(resp == 's'){
				break;
			}
		}
		else{
			if(tipo_animal == 'a'){
				remover(anfibios_nat, anfibios_ex); // Função remover sobrecarregada.
			}
			else if(tipo_animal == 'm'){
				remover(mamiferos_nat, mamiferos_ex);
			}
			else if(tipo_animal == 'r'){
				remover(repteis_nat, repteis_ex);
			}
			else{
				remover(aves_nat, aves_ex);
			}
		
		} // Primeiro else.
	}while(op == 's');
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x28, %rsp
movq %r9, -0x38(%rbp)
movq %r8, %r13
movq %rcx, -0x48(%rbp)
movq %rdx, -0x40(%rbp)
movq %rsi, %r14
movq %rdi, %r15
movq 0x14e6b(%rip), %rbx     # 0x47fd0
leaq 0x825b(%rip), %rsi      # 0x3b3c7
movl $0x50, %edx
movq %rbx, %rdi
callq 0x3250
movq (%rbx), %rax
movq -0x18(%rax), %rdi
addq %rbx, %rdi
movl $0xa, %esi
callq 0x31f0
movsbl %al, %esi
movq %rbx, %rdi
callq 0x3030
movq %rax, %rdi
callq 0x3130
movq 0x14e39(%rip), %rdi     # 0x47fe0
leaq -0x2a(%rbp), %r12
movq %r12, %rsi
callq 0x3280
movzbl (%r12), %eax
cmpl $0x71, %eax
jg 0x331dd
cmpl $0x61, %eax
je 0x332ac
cmpl $0x6d, %eax
jne 0x331fd
movq -0x40(%rbp), %rdi
movq -0x48(%rbp), %rsi
callq 0x339e6
jmp 0x332c5
cmpl $0x72, %eax
je 0x332b9
cmpl $0x76, %eax
jne 0x331fd
movq 0x18(%rbp), %rsi
movq 0x10(%rbp), %rdi
callq 0x3480a
jmp 0x332c5
leaq 0x800d(%rip), %rsi      # 0x3b211
movl $0x25, %edx
movq %rbx, %rdi
callq 0x3250
movq (%rbx), %rax
movq -0x18(%rax), %rdi
addq %rbx, %rdi
movl $0xa, %esi
callq 0x31f0
movsbl %al, %esi
movq %rbx, %rdi
callq 0x3030
movq %rax, %rdi
callq 0x3130
movq (%rbx), %rax
movq -0x18(%rax), %rdi
addq %rbx, %rdi
movl $0xa, %esi
callq 0x31f0
movsbl %al, %esi
movq %rbx, %rdi
callq 0x3030
movq %rax, %rdi
callq 0x3130
leaq 0x73b2(%rip), %rsi      # 0x3a618
movl $0x10, %edx
movq %rbx, %rdi
callq 0x3250
movq (%rbx), %rax
movq -0x18(%rax), %rdi
addq %rbx, %rdi
movl $0xa, %esi
callq 0x31f0
movsbl %al, %esi
movq %rbx, %rdi
callq 0x3030
movq %rax, %rdi
callq 0x3130
movq 0x14d3f(%rip), %rdi     # 0x47fe0
leaq -0x29(%rbp), %rsi
callq 0x3280
jmp 0x332c5
movq %r15, %rdi
movq %r14, %rsi
callq 0x332d4
jmp 0x332c5
movq %r13, %rdi
movq -0x38(%rbp), %rsi
callq 0x340f8
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq