use unique_ptrs for the list structure