// File: AshOlogn[P]ash-language-interpreter/src/errors.cpp
// Function: StaticCastError::what() const
const char* StaticCastError::what() const throw() {

  std::string str = "";

  if(startLineNumber == endLineNumber) {
    str.append("StaticCastError on line ");
    str.append(std::to_string(startLineNumber));
  } else {
    str.append("StaticCastError from line ");
    str.append(std::to_string(startLineNumber));
    str.append(" to line ");
    str.append(std::to_string(endLineNumber));
  }

  str.append("\n");
  str.append(context);

	if(message != NULL) {
		str.append(message);
		return copyString(str.c_str());
	}

  if(isExplicit) {
    str.append("Cannot cast at all from type ");
  } else {
    str.append("Cannot implicitly cast from type ");
  }
  
  str.append(toStringParseDataType(originalType));
  str.append(" to type ");
  str.append(toStringParseDataType(finalType));

  return copyString(str.c_str());
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0xe0, %rsp
movq %rdi, -0x10(%rbp)
movq -0x10(%rbp), %rax
movq %rax, -0xc0(%rbp)
leaq -0x31(%rbp), %rdi
movq %rdi, -0xb8(%rbp)
callq 0x4430
movq -0xb8(%rbp), %rdx
leaq 0x384ed(%rip), %rsi     # 0x3f035
leaq -0x30(%rbp), %rdi
callq 0x4350
jmp 0x6b53
leaq -0x31(%rbp), %rdi
callq 0x4290
movq -0xc0(%rbp), %rcx
movl 0x24(%rcx), %eax
cmpl 0x28(%rcx), %eax
jne 0x6bf8
leaq 0x386a1(%rip), %rsi     # 0x3f217
leaq -0x30(%rbp), %rdi
callq 0x4460
jmp 0x6b81
movq -0xc0(%rbp), %rax
movl 0x24(%rax), %esi
leaq -0x68(%rbp), %rdi
callq 0x6e40
jmp 0x6b96
leaq -0x30(%rbp), %rdi
leaq -0x68(%rbp), %rsi
callq 0x4470
jmp 0x6ba5
leaq -0x68(%rbp), %rdi
callq 0x4170
jmp 0x6cc4
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x40(%rbp)
movl %eax, -0x44(%rbp)
leaq -0x31(%rbp), %rdi
callq 0x4290
jmp 0x6e2d
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x40(%rbp)
movl %eax, -0x44(%rbp)
jmp 0x6e24
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x40(%rbp)
movl %eax, -0x44(%rbp)
leaq -0x68(%rbp), %rdi
callq 0x4170
jmp 0x6e24
leaq 0x38631(%rip), %rsi     # 0x3f230
leaq -0x30(%rbp), %rdi
callq 0x4460
jmp 0x6c0a
movq -0xc0(%rbp), %rax
movl 0x24(%rax), %esi
leaq -0x88(%rbp), %rdi
callq 0x6e40
jmp 0x6c22
leaq -0x30(%rbp), %rdi
leaq -0x88(%rbp), %rsi
callq 0x4470
jmp 0x6c34
leaq -0x88(%rbp), %rdi
callq 0x4170
leaq 0x38485(%rip), %rsi     # 0x3f0cc
leaq -0x30(%rbp), %rdi
callq 0x4460
jmp 0x6c52
movq -0xc0(%rbp), %rax
movl 0x28(%rax), %esi
leaq -0xa8(%rbp), %rdi
callq 0x6e40
jmp 0x6c6a
leaq -0x30(%rbp), %rdi
leaq -0xa8(%rbp), %rsi
callq 0x4470
jmp 0x6c7c
leaq -0xa8(%rbp), %rdi
callq 0x4170
jmp 0x6cc4
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x40(%rbp)
movl %eax, -0x44(%rbp)
leaq -0x88(%rbp), %rdi
callq 0x4170
jmp 0x6e24
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x40(%rbp)
movl %eax, -0x44(%rbp)
leaq -0xa8(%rbp), %rdi
callq 0x4170
jmp 0x6e24
leaq 0x3d859(%rip), %rsi     # 0x44524
leaq -0x30(%rbp), %rdi
callq 0x4460
jmp 0x6cd6
movq -0xc0(%rbp), %rax
movq 0x10(%rax), %rsi
leaq -0x30(%rbp), %rdi
callq 0x4460
jmp 0x6cec
movq -0xc0(%rbp), %rax
cmpq $0x0, 0x18(%rax)
je 0x6d44
movq -0xc0(%rbp), %rax
movq 0x18(%rax), %rsi
leaq -0x30(%rbp), %rdi
callq 0x4460
jmp 0x6d10
leaq -0x30(%rbp), %rdi
callq 0x40e0
movq %rax, %rdi
callq 0x2fb10
movq %rax, -0xc8(%rbp)
jmp 0x6d2a
movq -0xc8(%rbp), %rax
movq %rax, -0x8(%rbp)
movl $0x1, -0xac(%rbp)
jmp 0x6e0e
movq -0xc0(%rbp), %rax
testb $0x1, 0x20(%rax)
je 0x6d65
leaq 0x384f3(%rip), %rsi     # 0x3f24b
leaq -0x30(%rbp), %rdi
callq 0x4460
jmp 0x6d63
jmp 0x6d79
leaq 0x384fd(%rip), %rsi     # 0x3f269
leaq -0x30(%rbp), %rdi
callq 0x4460
jmp 0x6d77
jmp 0x6d79
movq -0xc0(%rbp), %rax
movl 0x8(%rax), %edi
callq 0xb8a0
movq %rax, -0xd0(%rbp)
jmp 0x6d91
movq -0xd0(%rbp), %rsi
leaq -0x30(%rbp), %rdi
callq 0x4460
jmp 0x6da3
leaq 0x384e1(%rip), %rsi     # 0x3f28b
leaq -0x30(%rbp), %rdi
callq 0x4460
jmp 0x6db5
movq -0xc0(%rbp), %rax
movl 0xc(%rax), %edi
callq 0xb8a0
movq %rax, -0xd8(%rbp)
jmp 0x6dcd
movq -0xd8(%rbp), %rsi
leaq -0x30(%rbp), %rdi
callq 0x4460
jmp 0x6ddf
leaq -0x30(%rbp), %rdi
callq 0x40e0
movq %rax, %rdi
callq 0x2fb10
movq %rax, -0xe0(%rbp)
jmp 0x6df9
movq -0xe0(%rbp), %rax
movq %rax, -0x8(%rbp)
movl $0x1, -0xac(%rbp)
leaq -0x30(%rbp), %rdi
callq 0x4170
movq -0x8(%rbp), %rax
addq $0xe0, %rsp
popq %rbp
retq
leaq -0x30(%rbp), %rdi
callq 0x4170
movq -0x40(%rbp), %rdi
callq 0x42e0
nopw %cs:(%rax,%rax)