Fix up TODO: c++0x, update cpplint.
Needed to update cpplint to handle const auto.
Fixed a few cpplint errors that were being missed before.
Replaced most of the TODO c++0x with ranged based loops. Loops which
do not have a descriptive container name have a concrete type instead
of auto.
Change-Id: Id7cc0f27030f56057c544e94277300b3f298c9c5
diff --git a/runtime/monitor.cc b/runtime/monitor.cc
index 48c0569..ff193c9 100644
--- a/runtime/monitor.cc
+++ b/runtime/monitor.cc
@@ -979,9 +979,7 @@
void MonitorList::SweepMonitorList(IsMarkedTester is_marked, void* arg) {
MutexLock mu(Thread::Current(), monitor_list_lock_);
- typedef std::list<Monitor*>::iterator It; // TODO: C++0x auto
- It it = list_.begin();
- while (it != list_.end()) {
+ for (auto it = list_.begin(); it != list_.end(); ) {
Monitor* m = *it;
if (!is_marked(m->GetObject(), arg)) {
VLOG(monitor) << "freeing monitor " << m << " belonging to unmarked object " << m->GetObject();