Doubly-linked list implementation