// File: /workspace/github_cpp_makefile_star2_O1/MechaDragonX[P]CPPCollections/linked_list.cpp
// Function: LinkedList<int>::toString[abi:cxx11]()
std::string LinkedList<T>::toString() {
    ListNode<T>* current = head_;
    std::string output = "";
    while(current != nullptr) {
        if(current->next != nullptr) {
            // If type is Student
            if constexpr (std::is_same<T, Student>::value)
                output += current->value.toString(false) + " => ";
            // If type is std::string
            else if constexpr (std::is_same<T, std::string>::value)
                output += current->value + " => ";
            // Otherwise, it's a primitive
            else
                output += std::to_string(current->value) + " => ";
        }
        else {
            // If type is Student
            if constexpr (std::is_same<T, Student>::value)
                output += current->value.toString(false);
            // If type is std::string
            else if constexpr (std::is_same<T, std::string>::value)
                output += current->value;
            // Otherwise, it's a primitive
            else
                output += std::to_string(current->value);
        }

        current = current->next;
    }
    return output;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x58, %rsp
movq 0x8(%rsi), %r14
leaq 0x10(%rdi), %rax
movq %rax, -0x58(%rbp)
movq %rax, (%rdi)
leaq 0xa565(%rip), %rdx      # 0x103be
movq %rdi, -0x30(%rbp)
movq %rdx, %rsi
callq 0x5bd8
testq %r14, %r14
je 0x6085
leaq -0x40(%rbp), %rbx
movl $0xd1b71759, %edx       # imm = 0xD1B71759
leaq -0x78(%rbp), %r15
cmpq $0x0, 0x8(%r14)
je 0x5ee8
movq %r14, -0x80(%rbp)
movl (%r14), %r13d
movl %r13d, %r14d
negl %r14d
cmovsl %r13d, %r14d
movl $0x1, %r12d
cmpl $0xa, %r14d
jb 0x5f59
movl $0x4, %r12d
movl %r14d, %eax
cmpl $0x63, %eax
jbe 0x5f50
cmpl $0x3e7, %eax            # imm = 0x3E7
jbe 0x5f56
cmpl $0x2710, %eax           # imm = 0x2710
jb 0x5f59
movl %eax, %ecx
imulq %rdx, %rcx
shrq $0x2d, %rcx
addl $0x4, %r12d
cmpl $0x1869f, %eax          # imm = 0x1869F
movl %ecx, %eax
ja 0x5eac
addl $-0x3, %r12d
jmp 0x5f59
movq %r14, %r15
movl (%r14), %r13d
movl %r13d, %r14d
negl %r14d
cmovsl %r13d, %r14d
movl $0x1, %r12d
cmpl $0xa, %r14d
jb 0x601a
movl $0x4, %r12d
movl %r14d, %eax
cmpl $0x63, %eax
jbe 0x6011
cmpl $0x3e7, %eax            # imm = 0x3E7
jbe 0x6017
cmpl $0x2710, %eax           # imm = 0x2710
jb 0x601a
movl %eax, %ecx
imulq %rdx, %rcx
shrq $0x2d, %rcx
addl $0x4, %r12d
cmpl $0x1869f, %eax          # imm = 0x1869F
movl %ecx, %eax
ja 0x5f11
addl $-0x3, %r12d
jmp 0x601a
addl $-0x2, %r12d
jmp 0x5f59
decl %r12d
shrl $0x1f, %r13d
leal (%r12,%r13), %esi
leaq -0x68(%rbp), %rax
movq %rax, -0x78(%rbp)
movq %r15, %rdi
movl $0x2d, %edx
callq 0x3170
addq -0x78(%rbp), %r13
movq %r13, %rdi
movl %r12d, %esi
movl %r14d, %edx
callq 0x582c
movq %r15, %rdi
leaq 0xa072(%rip), %rsi      # 0x10004
callq 0x3200
movq %rbx, -0x50(%rbp)
movq (%rax), %rdx
movq %rax, %rcx
addq $0x10, %rcx
cmpq %rcx, %rdx
movq -0x80(%rbp), %r14
je 0x5fbb
movq %rdx, -0x50(%rbp)
movq (%rcx), %rdx
movq %rdx, -0x40(%rbp)
jmp 0x5fc1
movups (%rcx), %xmm0
movups %xmm0, (%rbx)
movq 0x8(%rax), %rdx
movq %rdx, -0x48(%rbp)
movq %rcx, (%rax)
movq $0x0, 0x8(%rax)
movb $0x0, 0x10(%rax)
movq -0x50(%rbp), %rsi
movq -0x48(%rbp), %rdx
movq -0x30(%rbp), %rdi
callq 0x3070
movq -0x50(%rbp), %rdi
cmpq %rbx, %rdi
je 0x5ffe
movq -0x40(%rbp), %rsi
incq %rsi
callq 0x3140
movq -0x78(%rbp), %rdi
leaq -0x68(%rbp), %rax
cmpq %rax, %rdi
je 0x606f
movq -0x68(%rbp), %rsi
jmp 0x6067
addl $-0x2, %r12d
jmp 0x601a
decl %r12d
shrl $0x1f, %r13d
leal (%r12,%r13), %esi
movq %rbx, -0x50(%rbp)
leaq -0x50(%rbp), %rdi
movl $0x2d, %edx
callq 0x3170
addq -0x50(%rbp), %r13
movq %r13, %rdi
movl %r12d, %esi
movl %r14d, %edx
callq 0x582c
movq -0x50(%rbp), %rsi
movq -0x48(%rbp), %rdx
movq -0x30(%rbp), %rdi
callq 0x3070
movq -0x50(%rbp), %rdi
cmpq %rbx, %rdi
movq %r15, %r14
je 0x606f
movq -0x40(%rbp), %rsi
incq %rsi
callq 0x3140
movq 0x8(%r14), %r14
testq %r14, %r14
movl $0xd1b71759, %edx       # imm = 0xD1B71759
leaq -0x78(%rbp), %r15
jne 0x5e7b
movq -0x30(%rbp), %rax
addq $0x58, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0x60c6
movq %rax, %r14
movq -0x50(%rbp), %rdi
cmpq %rbx, %rdi
je 0x60e7
movq -0x40(%rbp), %rsi
jmp 0x60df
movq %rax, %r14
movq -0x50(%rbp), %rdi
cmpq %rbx, %rdi
je 0x60ce
movq -0x40(%rbp), %rsi
incq %rsi
callq 0x3140
jmp 0x60ce
movq %rax, %r14
jmp 0x60e7
movq %rax, %r14
movq -0x78(%rbp), %rdi
leaq -0x68(%rbp), %rax
cmpq %rax, %rdi
je 0x60e7
movq -0x68(%rbp), %rsi
incq %rsi
callq 0x3140
movq -0x30(%rbp), %rax
movq (%rax), %rdi
cmpq -0x58(%rbp), %rdi
je 0x6103
movq -0x58(%rbp), %rax
movq (%rax), %rsi
incq %rsi
callq 0x3140
movq %r14, %rdi
callq 0x31e0
nop