Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(193)

Unified Diff: third_party/WebKit/Source/core/dom/custom/V0CustomElementAsyncImportMicrotaskQueue.cpp

Issue 2553343002: Avoid WTF::Vector::at() and operator[] in core/dom. (Closed)
Patch Set: Created 4 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/Source/core/dom/custom/V0CustomElementAsyncImportMicrotaskQueue.cpp
diff --git a/third_party/WebKit/Source/core/dom/custom/V0CustomElementAsyncImportMicrotaskQueue.cpp b/third_party/WebKit/Source/core/dom/custom/V0CustomElementAsyncImportMicrotaskQueue.cpp
index 67b29afcbc229162e9caab281d23b0abed495555..a1061215b25cc947bac8ecf21b440f1c33383ab6 100644
--- a/third_party/WebKit/Source/core/dom/custom/V0CustomElementAsyncImportMicrotaskQueue.cpp
+++ b/third_party/WebKit/Source/core/dom/custom/V0CustomElementAsyncImportMicrotaskQueue.cpp
@@ -42,9 +42,9 @@ void V0CustomElementAsyncImportMicrotaskQueue::enqueue(
void V0CustomElementAsyncImportMicrotaskQueue::doDispatch() {
HeapVector<Member<V0CustomElementMicrotaskStep>> remaining;
- for (unsigned i = 0; i < m_queue.size(); ++i) {
- if (V0CustomElementMicrotaskStep::Processing == m_queue[i]->process())
- remaining.append(m_queue[i].release());
+ for (auto& step : m_queue) {
+ if (V0CustomElementMicrotaskStep::Processing == step->process())
+ remaining.append(step.release());
}
m_queue.swap(remaining);

Powered by Google App Engine
This is Rietveld 408576698