Join GitHub today
GitHub is home to over 20 million developers working together to host and review code, manage projects, and build software together.
Add remove() from the middle, along with insertBefore() and insertAfter() given item #5
I've added a couple of changes as listed in the title to the code. See here: OJezu/fast-list@5606a22
I needed a structure that allowed me to keep entries in an order, while allowing me to remove some arbitrary entries from the middle. I found this double-linked list, and added some functions and altering the ones already present. I changed push() and unshift(), so that they return a reference that can be later given to the new functions above, in order to insert/remove elements into/from the middle of the list.
I would like to add one more (or two) benchmark, and update the doc. I should have a pull request ready tomorrow.
What do you think?