Index: cc/scoped_ptr_vector.h |
diff --git a/cc/scoped_ptr_vector.h b/cc/scoped_ptr_vector.h |
index 2a8d9610a69c6f02f894b3bfd9203955a40c5867..5971daf775ac1d0266caa13131f4a176b12eba98 100644 |
--- a/cc/scoped_ptr_vector.h |
+++ b/cc/scoped_ptr_vector.h |
@@ -139,6 +139,11 @@ class ScopedPtrVector { |
std::swap(*writable_a, *writable_b); |
} |
+ template<class Compare> |
+ inline void sort(Compare comp) { |
+ std::sort(data_.begin(), data_.end(), comp); |
+ } |
+ |
iterator begin() { return static_cast<iterator>(data_.begin()); } |
const_iterator begin() const { return data_.begin(); } |
iterator end() { return static_cast<iterator>(data_.end()); } |