Index: src/list.h |
diff --git a/src/list.h b/src/list.h |
index 65645c9a53cee473d183d8f40efc9fc9bfcbbc21..71aa821959faa7c9a6948c336fc02cf3271c8d9d 100644 |
--- a/src/list.h |
+++ b/src/list.h |
@@ -91,6 +91,10 @@ class List { |
inline T& last() const { return at(length_ - 1); } |
inline T& first() const { return at(0); } |
+ typedef T* iterator; |
+ inline iterator begin() const { return &data_[0]; } |
+ inline iterator end() const { return &data_[length_]; } |
+ |
INLINE(bool is_empty() const) { return length_ == 0; } |
INLINE(int length() const) { return length_; } |
INLINE(int capacity() const) { return capacity_; } |