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

Unified Diff: third_party/WebKit/Source/core/dom/NthIndexCache.cpp

Issue 2709033003: Migrate WTF::HashMap::get() to ::at() (Closed)
Patch Set: rebase 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 side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/Source/core/dom/NthIndexCache.cpp
diff --git a/third_party/WebKit/Source/core/dom/NthIndexCache.cpp b/third_party/WebKit/Source/core/dom/NthIndexCache.cpp
index dad4c1daec63b1f6e3f189c4a85f30c214b34640..4db6bce365cee5afa2ab943e06700f35ec6536dc 100644
--- a/third_party/WebKit/Source/core/dom/NthIndexCache.cpp
+++ b/third_party/WebKit/Source/core/dom/NthIndexCache.cpp
@@ -84,7 +84,7 @@ unsigned NthIndexCache::nthChildIndex(Element& element) {
NthIndexCache* nthIndexCache = element.document().nthIndexCache();
NthIndexData* nthIndexData = nullptr;
if (nthIndexCache && nthIndexCache->m_parentMap)
- nthIndexData = nthIndexCache->m_parentMap->get(element.parentNode());
+ nthIndexData = nthIndexCache->m_parentMap->at(element.parentNode());
if (nthIndexData)
return nthIndexData->nthIndex(element);
unsigned index = uncachedNthChildIndex(element);
@@ -99,7 +99,7 @@ unsigned NthIndexCache::nthLastChildIndex(Element& element) {
NthIndexCache* nthIndexCache = element.document().nthIndexCache();
NthIndexData* nthIndexData = nullptr;
if (nthIndexCache && nthIndexCache->m_parentMap)
- nthIndexData = nthIndexCache->m_parentMap->get(element.parentNode());
+ nthIndexData = nthIndexCache->m_parentMap->at(element.parentNode());
if (nthIndexData)
return nthIndexData->nthLastIndex(element);
unsigned index = uncachedNthLastChildIndex(element);
@@ -112,8 +112,8 @@ NthIndexData* NthIndexCache::nthTypeIndexDataForParent(Element& element) const {
DCHECK(element.parentNode());
if (!m_parentMapForType)
return nullptr;
- if (const IndexByType* map = m_parentMapForType->get(element.parentNode()))
- return map->get(element.tagName());
+ if (const IndexByType* map = m_parentMapForType->at(element.parentNode()))
+ return map->at(element.tagName());
return nullptr;
}
« no previous file with comments | « third_party/WebKit/Source/core/dom/NodeListsNodeData.h ('k') | third_party/WebKit/Source/core/dom/ProcessingInstruction.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698