Chromium Code Reviews| Index: base/scoped_vector.h |
| diff --git a/base/scoped_vector.h b/base/scoped_vector.h |
| index 9d372f33009b613de3584fe12bd69cbface5b391..cbb7d0ba6fb03c41ff133dcb9ef3790b5e387b5c 100644 |
| --- a/base/scoped_vector.h |
| +++ b/base/scoped_vector.h |
| @@ -54,6 +54,10 @@ class ScopedVector { |
| } |
| void reset() { STLDeleteElements(&v); } |
| + void reset(const std::vector<T*>& vec) { |
|
James Hawkins
2011/03/16 22:39:35
You're essentially adding operator= by another nam
Sheridan Rawlins
2011/03/18 15:45:48
Ok, discussing alternative as you know on chromium
Sheridan Rawlins
2011/03/20 08:13:11
I'd like to tackle the idea of moving ScopedVector
|
| + reset(); |
| + v = vec; |
| + } |
|
stuartmorgan
2011/03/16 23:25:20
I don't feel comfortable being the reviewer for ad
Sheridan Rawlins
2011/03/18 15:45:48
This may be moot if I take alternative. o/w I'll
Sheridan Rawlins
2011/03/20 08:13:11
Nico seems to have some commits in base/scoped_vec
|
| void reserve(size_t capacity) { v.reserve(capacity); } |
| void resize(size_t new_size) { v.resize(new_size); } |