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

Unified Diff: Source/core/html/parser/AtomicHTMLToken.h

Issue 656723005: Use C++11 features in core/html (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: mike's comments Created 6 years, 1 month 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
« no previous file with comments | « Source/core/html/imports/LinkImport.cpp ('k') | Source/core/html/parser/BackgroundHTMLParser.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/html/parser/AtomicHTMLToken.h
diff --git a/Source/core/html/parser/AtomicHTMLToken.h b/Source/core/html/parser/AtomicHTMLToken.h
index 720736cdea5a0229ea256eae03f67cb93b2970ce..9f6d44e49a3545c1548e2bb391790a2cb2e915f1 100644
--- a/Source/core/html/parser/AtomicHTMLToken.h
+++ b/Source/core/html/parser/AtomicHTMLToken.h
@@ -162,11 +162,11 @@ public:
break;
case HTMLToken::StartTag:
m_attributes.reserveInitialCapacity(token.attributes().size());
- for (Vector<CompactHTMLToken::Attribute>::const_iterator it = token.attributes().begin(); it != token.attributes().end(); ++it) {
- QualifiedName name(nullAtom, AtomicString(it->name), nullAtom);
+ for (const CompactHTMLToken::Attribute& attribute : token.attributes()) {
+ QualifiedName name(nullAtom, AtomicString(attribute.name), nullAtom);
// FIXME: This is N^2 for the number of attributes.
if (!findAttributeInVector(m_attributes, name))
- m_attributes.append(Attribute(name, AtomicString(it->value)));
+ m_attributes.append(Attribute(name, AtomicString(attribute.value)));
}
// Fall through!
case HTMLToken::EndTag:
« no previous file with comments | « Source/core/html/imports/LinkImport.cpp ('k') | Source/core/html/parser/BackgroundHTMLParser.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698