diff --git a/src/util/IntrusiveList.hxx b/src/util/IntrusiveList.hxx index 319137744..c785fad68 100644 --- a/src/util/IntrusiveList.hxx +++ b/src/util/IntrusiveList.hxx @@ -507,6 +507,13 @@ public: ++counter; } + /** + * Like insert(), but insert after the given position. + */ + void insert_after(iterator p, reference t) noexcept { + insert(std::next(p), t); + } + /** * Move one item of the given list to this one before the * given position.