Index: base/id_map.h |
diff --git a/base/id_map.h b/base/id_map.h |
index b108dbd8755f706c49cecd555cac7815e0bf8ba7..acfba42bb94a61b1beeeeb128f2a7abe9090a603 100644 |
--- a/base/id_map.h |
+++ b/base/id_map.h |
@@ -82,7 +82,7 @@ class IDMap { |
} |
bool IsEmpty() const { |
- return data_.empty(); |
+ return size() == 0u; |
} |
T* Lookup(KeyType id) const { |
@@ -93,7 +93,7 @@ class IDMap { |
} |
size_t size() const { |
- return data_.size(); |
+ return data_.size() - removed_ids_.size(); |
} |
// It is safe to remove elements from the map during iteration. All iterators |