summaryrefslogtreecommitdiff
path: root/o3tl
diff options
context:
space:
mode:
Diffstat (limited to 'o3tl')
-rw-r--r--o3tl/inc/o3tl/sorted_vector.hxx12
1 files changed, 12 insertions, 0 deletions
diff --git a/o3tl/inc/o3tl/sorted_vector.hxx b/o3tl/inc/o3tl/sorted_vector.hxx
index b3ffc4ff8d41..bf1cca5eb937 100644
--- a/o3tl/inc/o3tl/sorted_vector.hxx
+++ b/o3tl/inc/o3tl/sorted_vector.hxx
@@ -67,6 +67,18 @@ public:
base_t::erase( begin_nonconst() + index );
}
+ // hack: public erase with const_iterator, should not change sort order
+ void erase(const_iterator const& position)
+ {
+ base_t::erase(begin_nonconst() + (position - begin()));
+ }
+
+ void erase(const_iterator const& first, const_iterator const& last)
+ {
+ base_t::erase(begin_nonconst() + (first - begin()),
+ begin_nonconst() + (last - begin()));
+ }
+
// ACCESSORS
// Only return a const iterator, so that the vector cannot be directly updated.