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

Unified Diff: third_party/WebKit/Source/core/dom/AttributeCollection.h

Issue 2390543002: Reflow comments in core/dom/. (Closed)
Patch Set: Reformat comments in core/dom/. Created 4 years, 2 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/AttributeCollection.h
diff --git a/third_party/WebKit/Source/core/dom/AttributeCollection.h b/third_party/WebKit/Source/core/dom/AttributeCollection.h
index 0d74d678297fb14124ce0ad85b3d7182dff9a8a4..6221ae9f96389e176457106507c470903e95be8c 100644
--- a/third_party/WebKit/Source/core/dom/AttributeCollection.h
+++ b/third_party/WebKit/Source/core/dom/AttributeCollection.h
@@ -149,8 +149,9 @@ AttributeCollectionGeneric<Container, ContainerMemberType>::findIndex(
return kNotFound;
}
-// We use a boolean parameter instead of calling shouldIgnoreAttributeCase so that the caller
-// can tune the behavior (hasAttribute is case sensitive whereas getAttribute is not).
+// We use a boolean parameter instead of calling shouldIgnoreAttributeCase so
+// that the caller can tune the behavior (hasAttribute is case sensitive whereas
+// getAttribute is not).
template <typename Container, typename ContainerMemberType>
inline size_t
AttributeCollectionGeneric<Container, ContainerMemberType>::findIndex(
@@ -158,7 +159,8 @@ AttributeCollectionGeneric<Container, ContainerMemberType>::findIndex(
bool shouldIgnoreCase) const {
bool doSlowCheck = shouldIgnoreCase;
- // Optimize for the case where the attribute exists and its name exactly matches.
+ // Optimize for the case where the attribute exists and its name exactly
+ // matches.
iterator end = this->end();
unsigned index = 0;
for (iterator it = begin(); it != end; ++it, ++index) {
@@ -194,7 +196,8 @@ template <typename Container, typename ContainerMemberType>
size_t AttributeCollectionGeneric<Container, ContainerMemberType>::findSlowCase(
const AtomicString& name,
bool shouldIgnoreAttributeCase) const {
- // Continue to checking case-insensitively and/or full namespaced names if necessary:
+ // Continue to checking case-insensitively and/or full namespaced names if
+ // necessary:
iterator end = this->end();
unsigned index = 0;
for (iterator it = begin(); it != end; ++it, ++index) {
@@ -204,9 +207,9 @@ size_t AttributeCollectionGeneric<Container, ContainerMemberType>::findSlowCase(
if (shouldIgnoreAttributeCase && equalIgnoringCase(name, it->localName()))
return index;
} else {
- // FIXME: Would be faster to do this comparison without calling toString, which
- // generates a temporary string by concatenation. But this branch is only reached
- // if the attribute name has a prefix, which is rare in HTML.
+ // FIXME: Would be faster to do this comparison without calling toString,
+ // which generates a temporary string by concatenation. But this branch is
+ // only reached if the attribute name has a prefix, which is rare in HTML.
if (equalPossiblyIgnoringCase(name, it->name().toString(),
shouldIgnoreAttributeCase))
return index;
« no previous file with comments | « third_party/WebKit/Source/core/dom/Attribute.h ('k') | third_party/WebKit/Source/core/dom/CSSSelectorWatch.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698