// File: /workspace/github_cpp_makefile_star2_O3/brashi[P]PetFera/src/./petshop.cpp
// Function: Petshop::criarVeterinario()
void Petshop::criarVeterinario() {
    string nome;
    shared_ptr<Veterinario> veterinario = make_shared<Veterinario>();

    if(veterinario->setNome())
        nome = veterinario->getNome();
    else
        throw "Veterinário deve ter um nome válido!";

    if(this->findVeterinario(nome) != nullptr)
        throw "Funcionário já existe!";

    if(!veterinario->setTelefone())
        throw "Veterinário não pode ficar sem telefone";

    if(!veterinario->setEmail())
        throw "Veterinário não pode ficar sem e-mail";

    if(!veterinario->setCRMV())
        throw "Veterinário não pode ficar sem CRMV";

    if(this->adicionarVeterinario(veterinario))
        cout << "Veterinário adicionado ao cadastro." << endl;
    else
        cout << "Houve um erro na operação" << endl << "Cancelando..." << endl;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x78, %rsp
movq %rdi, %r14
leaq 0x28(%rsp), %r13
movq %r13, -0x10(%r13)
movq $0x0, -0x8(%r13)
movb $0x0, (%r13)
movl $0x98, %edi
callq 0x52a0
movq %rax, %rbx
movabsq $0x100000001, %rax      # imm = 0x100000001
movq %rax, 0x8(%rbx)
leaq 0x1d045(%rip), %rax     # 0x29f38
movq %rax, (%rbx)
leaq 0x10(%rbx), %r15
leaq 0x28(%rbx), %rax
movq %rax, 0x18(%rbx)
xorl %eax, %eax
movq %rax, 0x20(%rbx)
movb %al, 0x28(%rbx)
leaq 0x48(%rbx), %rcx
movq %rcx, 0x38(%rbx)
movq %rax, 0x40(%rbx)
movb %al, 0x48(%rbx)
leaq 0x68(%rbx), %rcx
movq %rcx, 0x58(%rbx)
movq %rax, 0x60(%rbx)
movb %al, 0x68(%rbx)
leaq 0x1d278(%rip), %rcx     # 0x2a1a8
addq $0x10, %rcx
movq %rcx, 0x10(%rbx)
movq %rbx, %rcx
addq $0x88, %rcx
movq %rcx, 0x78(%rbx)
movq %rax, 0x80(%rbx)
movb %al, 0x88(%rbx)
movq %r15, %rdi
callq 0x1475a
testb %al, %al
je 0xd0e3
leaq 0x58(%rsp), %rdi
movq %r15, %rsi
callq 0x14736
leaq 0x18(%rsp), %rdi
leaq 0x58(%rsp), %r12
movq %r12, %rsi
callq 0x5330
movq (%r12), %rdi
leaq 0x68(%rsp), %rax
cmpq %rax, %rdi
je 0xcf9d
movq 0x68(%rsp), %rsi
incq %rsi
callq 0x52b0
leaq 0x48(%rsp), %r12
movq %r12, -0x10(%r12)
movq 0x18(%rsp), %rsi
movq 0x20(%rsp), %rdx
addq %rsi, %rdx
leaq 0x38(%rsp), %rdi
callq 0x9fc2
leaq 0x58(%rsp), %rdi
leaq 0x38(%rsp), %rdx
movq %r14, %rsi
callq 0xd190
movq 0x58(%rsp), %rbp
movq 0x60(%rsp), %rdi
testq %rdi, %rdi
je 0xcfe4
callq 0x9f52
movq 0x38(%rsp), %rdi
cmpq %r12, %rdi
je 0xcffb
movq 0x48(%rsp), %rsi
incq %rsi
callq 0x52b0
testq %rbp, %rbp
jne 0xd0ec
movq %r15, %rdi
callq 0x148da
testb %al, %al
je 0xd0f5
movq %r15, %rdi
callq 0x14a5a
testb %al, %al
je 0xd0fe
movq %r15, %rdi
callq 0x159be
testb %al, %al
je 0xd107
movq %r15, 0x8(%rsp)
movq %rbx, 0x10(%rsp)
movq 0x1df83(%rip), %rax     # 0x2afc8
cmpb $0x0, (%rax)
je 0xd04f
incl 0x8(%rbx)
jmp 0xd053
lock
incl 0x8(%rbx)
leaq 0x8(%rsp), %rsi
movq %r14, %rdi
callq 0x13964
movq 0x10(%rsp), %rdi
testq %rdi, %rdi
je 0xd06f
callq 0x9f52
movq 0x1df5a(%rip), %r14     # 0x2afd0
leaq 0x12f00(%rip), %rsi     # 0x1ff7d
movl $0x24, %edx
movq %r14, %rdi
callq 0x5310
movq (%r14), %rax
addq -0x18(%rax), %r14
movq %r14, %rdi
movl $0xa, %esi
callq 0x5280
movsbl %al, %esi
movq 0x1df28(%rip), %rdi     # 0x2afd0
callq 0x5030
movq %rax, %rdi
callq 0x51c0
movq %rbx, %rdi
callq 0x9f52
movq 0x18(%rsp), %rdi
cmpq %r13, %rdi
je 0xd0d4
movq 0x28(%rsp), %rsi
incq %rsi
callq 0x52b0
addq $0x78, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
leaq 0x12ddb(%rip), %r14     # 0x1fec5
jmp 0xd10e
leaq 0x12df9(%rip), %r14     # 0x1feec
jmp 0xd10e
leaq 0x12e09(%rip), %r14     # 0x1ff05
jmp 0xd10e
leaq 0x12e2a(%rip), %r14     # 0x1ff2f
jmp 0xd10e
leaq 0x12e49(%rip), %r14     # 0x1ff57
movl $0x8, %edi
callq 0x5170
movq %r14, (%rax)
movq 0x1de8e(%rip), %rsi     # 0x2afb0
movq %rax, %rdi
xorl %edx, %edx
callq 0x5440
movq %rax, %r14
movq 0x10(%rsp), %rdi
testq %rdi, %rdi
je 0xd168
callq 0x9f52
jmp 0xd168
movq %rax, %r14
movq 0x38(%rsp), %rdi
cmpq %r12, %rdi
je 0xd168
movq 0x48(%rsp), %rsi
incq %rsi
callq 0x52b0
jmp 0xd168
jmp 0xd165
jmp 0xd165
movq %rax, %r14
jmp 0xd170
movq %rax, %r14
movq %rbx, %rdi
callq 0x9f52
movq 0x18(%rsp), %rdi
cmpq %r13, %rdi
je 0xd187
movq 0x28(%rsp), %rsi
incq %rsi
callq 0x52b0
movq %r14, %rdi
callq 0x5460
nop