diff --git a/flow/IndexedSet.h b/flow/IndexedSet.h index 2f4906acbf..070c136c3d 100644 --- a/flow/IndexedSet.h +++ b/flow/IndexedSet.h @@ -874,6 +874,8 @@ void IndexedSet::erase( typename IndexedSet::iterator begin, // Removes all nodes in the set between first and last, inclusive. // toFree is extended with the roots of completely removed subtrees. + ASSERT(!end.i || (begin.i && *begin <= *end)); + if(begin == end) return;