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

Side by Side Diff: third_party/WebKit/Source/modules/fetch/FetchManager.cpp

Issue 2696183002: Migrate WTF::HashSet::remove() to ::erase() [part 1] (Closed)
Patch Set: one more platform-specific reference Created 3 years, 10 months 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 unified diff | Download patch
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "modules/fetch/FetchManager.h" 5 #include "modules/fetch/FetchManager.h"
6 6
7 #include "bindings/core/v8/ExceptionState.h" 7 #include "bindings/core/v8/ExceptionState.h"
8 #include "bindings/core/v8/ScriptPromiseResolver.h" 8 #include "bindings/core/v8/ScriptPromiseResolver.h"
9 #include "bindings/core/v8/ScriptState.h" 9 #include "bindings/core/v8/ScriptState.h"
10 #include "bindings/core/v8/V8ThrowException.h" 10 #include "bindings/core/v8/V8ThrowException.h"
(...skipping 912 matching lines...) Expand 10 before | Expand all | Expand 10 after
923 loader->start(); 923 loader->start();
924 return promise; 924 return promise;
925 } 925 }
926 926
927 void FetchManager::contextDestroyed(ExecutionContext*) { 927 void FetchManager::contextDestroyed(ExecutionContext*) {
928 for (auto& loader : m_loaders) 928 for (auto& loader : m_loaders)
929 loader->dispose(); 929 loader->dispose();
930 } 930 }
931 931
932 void FetchManager::onLoaderFinished(Loader* loader) { 932 void FetchManager::onLoaderFinished(Loader* loader) {
933 m_loaders.remove(loader); 933 m_loaders.erase(loader);
934 loader->dispose(); 934 loader->dispose();
935 } 935 }
936 936
937 DEFINE_TRACE(FetchManager) { 937 DEFINE_TRACE(FetchManager) {
938 visitor->trace(m_loaders); 938 visitor->trace(m_loaders);
939 ContextLifecycleObserver::trace(visitor); 939 ContextLifecycleObserver::trace(visitor);
940 } 940 }
941 941
942 } // namespace blink 942 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698