<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN"
"http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head><meta http-equiv="content-type" content="text/html; charset=utf-8" />
<title>[160598] trunk/Source/WebCore</title>
</head>
<body>
<style type="text/css"><!--
#msg dl.meta { border: 1px #006 solid; background: #369; padding: 6px; color: #fff; }
#msg dl.meta dt { float: left; width: 6em; font-weight: bold; }
#msg dt:after { content:':';}
#msg dl, #msg dt, #msg ul, #msg li, #header, #footer, #logmsg { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt; }
#msg dl a { font-weight: bold}
#msg dl a:link { color:#fc3; }
#msg dl a:active { color:#ff0; }
#msg dl a:visited { color:#cc6; }
h3 { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt; font-weight: bold; }
#msg pre { overflow: auto; background: #ffc; border: 1px #fa0 solid; padding: 6px; }
#logmsg { background: #ffc; border: 1px #fa0 solid; padding: 1em 1em 0 1em; }
#logmsg p, #logmsg pre, #logmsg blockquote { margin: 0 0 1em 0; }
#logmsg p, #logmsg li, #logmsg dt, #logmsg dd { line-height: 14pt; }
#logmsg h1, #logmsg h2, #logmsg h3, #logmsg h4, #logmsg h5, #logmsg h6 { margin: .5em 0; }
#logmsg h1:first-child, #logmsg h2:first-child, #logmsg h3:first-child, #logmsg h4:first-child, #logmsg h5:first-child, #logmsg h6:first-child { margin-top: 0; }
#logmsg ul, #logmsg ol { padding: 0; list-style-position: inside; margin: 0 0 0 1em; }
#logmsg ul { text-indent: -1em; padding-left: 1em; }#logmsg ol { text-indent: -1.5em; padding-left: 1.5em; }
#logmsg > ul, #logmsg > ol { margin: 0 0 1em 0; }
#logmsg pre { background: #eee; padding: 1em; }
#logmsg blockquote { border: 1px solid #fa0; border-left-width: 10px; padding: 1em 1em 0 1em; background: white;}
#logmsg dl { margin: 0; }
#logmsg dt { font-weight: bold; }
#logmsg dd { margin: 0; padding: 0 0 0.5em 0; }
#logmsg dd:before { content:'\00bb';}
#logmsg table { border-spacing: 0px; border-collapse: collapse; border-top: 4px solid #fa0; border-bottom: 1px solid #fa0; background: #fff; }
#logmsg table th { text-align: left; font-weight: normal; padding: 0.2em 0.5em; border-top: 1px dotted #fa0; }
#logmsg table td { text-align: right; border-top: 1px dotted #fa0; padding: 0.2em 0.5em; }
#logmsg table thead th { text-align: center; border-bottom: 1px solid #fa0; }
#logmsg table th.Corner { text-align: left; }
#logmsg hr { border: none 0; border-top: 2px dashed #fa0; height: 1px; }
#header, #footer { color: #fff; background: #636; border: 1px #300 solid; padding: 6px; }
#patch { width: 100%; }
#patch h4 {font-family: verdana,arial,helvetica,sans-serif;font-size:10pt;padding:8px;background:#369;color:#fff;margin:0;}
#patch .propset h4, #patch .binary h4 {margin:0;}
#patch pre {padding:0;line-height:1.2em;margin:0;}
#patch .diff {width:100%;background:#eee;padding: 0 0 10px 0;overflow:auto;}
#patch .propset .diff, #patch .binary .diff {padding:10px 0;}
#patch span {display:block;padding:0 10px;}
#patch .modfile, #patch .addfile, #patch .delfile, #patch .propset, #patch .binary, #patch .copfile {border:1px solid #ccc;margin:10px 0;}
#patch ins {background:#dfd;text-decoration:none;display:block;padding:0 10px;}
#patch del {background:#fdd;text-decoration:none;display:block;padding:0 10px;}
#patch .lines, .info {color:#888;background:#fff;}
--></style>
<div id="msg">
<dl class="meta">
<dt>Revision</dt> <dd><a href="http://trac.webkit.org/projects/webkit/changeset/160598">160598</a></dd>
<dt>Author</dt> <dd>weinig@apple.com</dd>
<dt>Date</dt> <dd>2013-12-14 10:05:45 -0800 (Sat, 14 Dec 2013)</dd>
</dl>
<h3>Log Message</h3>
<pre>CTTE: Convert Element and RenderObject iterator usage to use range-based for loops
https://bugs.webkit.org/show_bug.cgi?id=125731
Reviewed by Andreas Kling.
Perform straight forward conversions. A few stragglers that do odd things remain.</pre>
<h3>Modified Paths</h3>
<ul>
<li><a href="#trunkSourceWebCoreChangeLog">trunk/Source/WebCore/ChangeLog</a></li>
<li><a href="#trunkSourceWebCoreaccessibilityAccessibilityNodeObjectcpp">trunk/Source/WebCore/accessibility/AccessibilityNodeObject.cpp</a></li>
<li><a href="#trunkSourceWebCoreaccessibilityAccessibilityRenderObjectcpp">trunk/Source/WebCore/accessibility/AccessibilityRenderObject.cpp</a></li>
<li><a href="#trunkSourceWebCoreaccessibilityAccessibilityTablecpp">trunk/Source/WebCore/accessibility/AccessibilityTable.cpp</a></li>
<li><a href="#trunkSourceWebCoredomChildNodeListcpp">trunk/Source/WebCore/dom/ChildNodeList.cpp</a></li>
<li><a href="#trunkSourceWebCoredomDocumentcpp">trunk/Source/WebCore/dom/Document.cpp</a></li>
<li><a href="#trunkSourceWebCoredomSelectorQuerycpp">trunk/Source/WebCore/dom/SelectorQuery.cpp</a></li>
<li><a href="#trunkSourceWebCoredomTreeScopecpp">trunk/Source/WebCore/dom/TreeScope.cpp</a></li>
<li><a href="#trunkSourceWebCoreeditingApplyStyleCommandcpp">trunk/Source/WebCore/editing/ApplyStyleCommand.cpp</a></li>
<li><a href="#trunkSourceWebCoreeditingmarkupcpp">trunk/Source/WebCore/editing/markup.cpp</a></li>
<li><a href="#trunkSourceWebCorehtmlHTMLAppletElementcpp">trunk/Source/WebCore/html/HTMLAppletElement.cpp</a></li>
<li><a href="#trunkSourceWebCorehtmlHTMLElementcpp">trunk/Source/WebCore/html/HTMLElement.cpp</a></li>
<li><a href="#trunkSourceWebCorehtmlHTMLFieldSetElementcpp">trunk/Source/WebCore/html/HTMLFieldSetElement.cpp</a></li>
<li><a href="#trunkSourceWebCorehtmlHTMLFormElementcpp">trunk/Source/WebCore/html/HTMLFormElement.cpp</a></li>
<li><a href="#trunkSourceWebCorehtmlHTMLLabelElementcpp">trunk/Source/WebCore/html/HTMLLabelElement.cpp</a></li>
<li><a href="#trunkSourceWebCorehtmlHTMLMapElementcpp">trunk/Source/WebCore/html/HTMLMapElement.cpp</a></li>
<li><a href="#trunkSourceWebCorehtmlHTMLMediaElementcpp">trunk/Source/WebCore/html/HTMLMediaElement.cpp</a></li>
<li><a href="#trunkSourceWebCorehtmlHTMLObjectElementcpp">trunk/Source/WebCore/html/HTMLObjectElement.cpp</a></li>
<li><a href="#trunkSourceWebCoreloaderPlaceholderDocumentcpp">trunk/Source/WebCore/loader/PlaceholderDocument.cpp</a></li>
<li><a href="#trunkSourceWebCorerenderingFilterEffectRenderercpp">trunk/Source/WebCore/rendering/FilterEffectRenderer.cpp</a></li>
<li><a href="#trunkSourceWebCorerenderingRenderBlockcpp">trunk/Source/WebCore/rendering/RenderBlock.cpp</a></li>
<li><a href="#trunkSourceWebCorerenderingRenderBlockFlowcpp">trunk/Source/WebCore/rendering/RenderBlockFlow.cpp</a></li>
<li><a href="#trunkSourceWebCorerenderingRenderBoxcpp">trunk/Source/WebCore/rendering/RenderBox.cpp</a></li>
<li><a href="#trunkSourceWebCorerenderingRenderElementcpp">trunk/Source/WebCore/rendering/RenderElement.cpp</a></li>
<li><a href="#trunkSourceWebCorerenderingRenderFrameSetcpp">trunk/Source/WebCore/rendering/RenderFrameSet.cpp</a></li>
<li><a href="#trunkSourceWebCorerenderingRenderInlinecpp">trunk/Source/WebCore/rendering/RenderInline.cpp</a></li>
<li><a href="#trunkSourceWebCorerenderingRenderTablecpp">trunk/Source/WebCore/rendering/RenderTable.cpp</a></li>
<li><a href="#trunkSourceWebCorerenderingRenderTextFragmentcpp">trunk/Source/WebCore/rendering/RenderTextFragment.cpp</a></li>
<li><a href="#trunkSourceWebCorerenderingRenderTreeAsTextcpp">trunk/Source/WebCore/rendering/RenderTreeAsText.cpp</a></li>
<li><a href="#trunkSourceWebCorerenderingRenderViewcpp">trunk/Source/WebCore/rendering/RenderView.cpp</a></li>
<li><a href="#trunkSourceWebCorerenderingmathmlRenderMathMLRootcpp">trunk/Source/WebCore/rendering/mathml/RenderMathMLRoot.cpp</a></li>
<li><a href="#trunkSourceWebCorerenderingmathmlRenderMathMLRowcpp">trunk/Source/WebCore/rendering/mathml/RenderMathMLRow.cpp</a></li>
<li><a href="#trunkSourceWebCorerenderingsvgRenderSVGContainercpp">trunk/Source/WebCore/rendering/svg/RenderSVGContainer.cpp</a></li>
<li><a href="#trunkSourceWebCorerenderingsvgRenderSVGResourceClippercpp">trunk/Source/WebCore/rendering/svg/RenderSVGResourceClipper.cpp</a></li>
<li><a href="#trunkSourceWebCorerenderingsvgRenderSVGResourceFiltercpp">trunk/Source/WebCore/rendering/svg/RenderSVGResourceFilter.cpp</a></li>
<li><a href="#trunkSourceWebCorerenderingsvgRenderSVGResourceMaskercpp">trunk/Source/WebCore/rendering/svg/RenderSVGResourceMasker.cpp</a></li>
<li><a href="#trunkSourceWebCorerenderingsvgRenderSVGResourcePatterncpp">trunk/Source/WebCore/rendering/svg/RenderSVGResourcePattern.cpp</a></li>
<li><a href="#trunkSourceWebCorerenderingsvgRenderSVGRootcpp">trunk/Source/WebCore/rendering/svg/RenderSVGRoot.cpp</a></li>
<li><a href="#trunkSourceWebCorerenderingsvgSVGResourcesCycleSolvercpp">trunk/Source/WebCore/rendering/svg/SVGResourcesCycleSolver.cpp</a></li>
<li><a href="#trunkSourceWebCoresvgSVGAltGlyphDefElementcpp">trunk/Source/WebCore/svg/SVGAltGlyphDefElement.cpp</a></li>
<li><a href="#trunkSourceWebCoresvgSVGAltGlyphItemElementcpp">trunk/Source/WebCore/svg/SVGAltGlyphItemElement.cpp</a></li>
<li><a href="#trunkSourceWebCoresvgSVGAnimateMotionElementcpp">trunk/Source/WebCore/svg/SVGAnimateMotionElement.cpp</a></li>
<li><a href="#trunkSourceWebCoresvgSVGElementcpp">trunk/Source/WebCore/svg/SVGElement.cpp</a></li>
<li><a href="#trunkSourceWebCoresvgSVGFEComponentTransferElementcpp">trunk/Source/WebCore/svg/SVGFEComponentTransferElement.cpp</a></li>
<li><a href="#trunkSourceWebCoresvgSVGFELightElementcpp">trunk/Source/WebCore/svg/SVGFELightElement.cpp</a></li>
<li><a href="#trunkSourceWebCoresvgSVGFEMergeElementcpp">trunk/Source/WebCore/svg/SVGFEMergeElement.cpp</a></li>
<li><a href="#trunkSourceWebCoresvgSVGFontElementcpp">trunk/Source/WebCore/svg/SVGFontElement.cpp</a></li>
<li><a href="#trunkSourceWebCoresvgSVGFontFaceSrcElementcpp">trunk/Source/WebCore/svg/SVGFontFaceSrcElement.cpp</a></li>
<li><a href="#trunkSourceWebCoresvgSVGGradientElementcpp">trunk/Source/WebCore/svg/SVGGradientElement.cpp</a></li>
<li><a href="#trunkSourceWebCoresvgSVGSVGElementcpp">trunk/Source/WebCore/svg/SVGSVGElement.cpp</a></li>
<li><a href="#trunkSourceWebCoresvgSVGSwitchElementcpp">trunk/Source/WebCore/svg/SVGSwitchElement.cpp</a></li>
<li><a href="#trunkSourceWebCoresvgSVGUseElementcpp">trunk/Source/WebCore/svg/SVGUseElement.cpp</a></li>
<li><a href="#trunkSourceWebCoresvganimationSMILTimeContainercpp">trunk/Source/WebCore/svg/animation/SMILTimeContainer.cpp</a></li>
</ul>
</div>
<div id="patch">
<h3>Diff</h3>
<a id="trunkSourceWebCoreChangeLog"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/ChangeLog (160597 => 160598)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/ChangeLog        2013-12-14 17:53:05 UTC (rev 160597)
+++ trunk/Source/WebCore/ChangeLog        2013-12-14 18:05:45 UTC (rev 160598)
</span><span class="lines">@@ -1,3 +1,12 @@
</span><ins>+2013-12-13 Sam Weinig <sam@webkit.org>
+
+ CTTE: Convert Element and RenderObject iterator usage to use range-based for loops
+ https://bugs.webkit.org/show_bug.cgi?id=125731
+
+ Reviewed by Andreas Kling.
+
+ Perform straight forward conversions. A few stragglers that do odd things remain.
+
</ins><span class="cx"> 2013-12-14 Joseph Pecoraro <pecoraro@apple.com>
</span><span class="cx">
</span><span class="cx"> Small string improvements to JSInjectedScriptHost::type and other bindings
</span></span></pre></div>
<a id="trunkSourceWebCoreaccessibilityAccessibilityNodeObjectcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/accessibility/AccessibilityNodeObject.cpp (160597 => 160598)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/accessibility/AccessibilityNodeObject.cpp        2013-12-14 17:53:05 UTC (rev 160597)
+++ trunk/Source/WebCore/accessibility/AccessibilityNodeObject.cpp        2013-12-14 18:05:45 UTC (rev 160598)
</span><span class="lines">@@ -1026,15 +1026,14 @@
</span><span class="cx">
</span><span class="cx"> // check if our parent is a mouse button listener
</span><span class="cx"> // FIXME: Do the continuation search like anchorElement does
</span><del>- auto lineage = elementLineage(node->isElementNode() ? toElement(node) : node->parentElement());
- for (auto element = lineage.begin(), end = lineage.end(); element != end; ++element) {
</del><ins>+ for (auto& element : elementLineage(node->isElementNode() ? toElement(node) : node->parentElement())) {
</ins><span class="cx"> // If we've reached the body and this is not a control element, do not expose press action for this element.
</span><span class="cx"> // It can cause false positives, where every piece of text is labeled as accepting press actions.
</span><del>- if (element->hasTagName(bodyTag) && isStaticText())
</del><ins>+ if (element.hasTagName(bodyTag) && isStaticText())
</ins><span class="cx"> break;
</span><span class="cx">
</span><del>- if (element->hasEventListeners(eventNames().clickEvent) || element->hasEventListeners(eventNames().mousedownEvent) || element->hasEventListeners(eventNames().mouseupEvent))
- return &*element;
</del><ins>+ if (element.hasEventListeners(eventNames().clickEvent) || element.hasEventListeners(eventNames().mousedownEvent) || element.hasEventListeners(eventNames().mouseupEvent))
+ return &element;
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> return 0;
</span><span class="lines">@@ -1166,21 +1165,21 @@
</span><span class="cx"> {
</span><span class="cx"> ContainerNode* parent = node->parentNode();
</span><span class="cx"> if (!parent)
</span><del>- return 0;
- auto children = elementChildren(*parent);
- for (auto sibling = children.begin(), end = children.end(); sibling != end; ++sibling) {
- const AtomicString& siblingAriaRole = sibling->fastGetAttribute(roleAttr);
</del><ins>+ return nullptr;
+
+ for (auto& sibling : elementChildren(*parent)) {
+ const AtomicString& siblingAriaRole = sibling.fastGetAttribute(roleAttr);
</ins><span class="cx"> if (equalIgnoringCase(siblingAriaRole, role))
</span><del>- return &*sibling;
</del><ins>+ return &sibling;
</ins><span class="cx"> }
</span><span class="cx">
</span><del>- return 0;
</del><ins>+ return nullptr;
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> Element* AccessibilityNodeObject::menuElementForMenuButton() const
</span><span class="cx"> {
</span><span class="cx"> if (ariaRoleAttribute() != MenuButtonRole)
</span><del>- return 0;
</del><ins>+ return nullptr;
</ins><span class="cx">
</span><span class="cx"> return siblingWithAriaRole("menu", node());
</span><span class="cx"> }
</span></span></pre></div>
<a id="trunkSourceWebCoreaccessibilityAccessibilityRenderObjectcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/accessibility/AccessibilityRenderObject.cpp (160597 => 160598)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/accessibility/AccessibilityRenderObject.cpp        2013-12-14 17:53:05 UTC (rev 160597)
+++ trunk/Source/WebCore/accessibility/AccessibilityRenderObject.cpp        2013-12-14 18:05:45 UTC (rev 160598)
</span><span class="lines">@@ -2754,13 +2754,12 @@
</span><span class="cx"> if (!map)
</span><span class="cx"> return;
</span><span class="cx">
</span><del>- auto areaDescendants = descendantsOfType<HTMLAreaElement>(*map);
- for (auto area = areaDescendants.begin(), end = areaDescendants.end(); area != end; ++area) {
</del><ins>+ for (auto& area : descendantsOfType<HTMLAreaElement>(*map)) {
</ins><span class="cx"> // add an <area> element for this child if it has a link
</span><del>- if (!area->isLink())
</del><ins>+ if (!area.isLink())
</ins><span class="cx"> continue;
</span><span class="cx"> AccessibilityImageMapLink* areaObject = toAccessibilityImageMapLink(axObjectCache()->getOrCreate(ImageMapLinkRole));
</span><del>- areaObject->setHTMLAreaElement(&*area);
</del><ins>+ areaObject->setHTMLAreaElement(&area);
</ins><span class="cx"> areaObject->setHTMLMapElement(map);
</span><span class="cx"> areaObject->setParent(this);
</span><span class="cx"> if (!areaObject->accessibilityIsIgnored())
</span></span></pre></div>
<a id="trunkSourceWebCoreaccessibilityAccessibilityTablecpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/accessibility/AccessibilityTable.cpp (160597 => 160598)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/accessibility/AccessibilityTable.cpp        2013-12-14 17:53:05 UTC (rev 160597)
+++ trunk/Source/WebCore/accessibility/AccessibilityTable.cpp        2013-12-14 18:05:45 UTC (rev 160598)
</span><span class="lines">@@ -124,9 +124,8 @@
</span><span class="cx"> return true;
</span><span class="cx">
</span><span class="cx"> // if there's a colgroup or col element, it's probably a data table.
</span><del>- auto tableChildren = elementChildren(*tableElement);
- for (auto child = tableChildren.begin(), end = tableChildren.end(); child != end; ++child) {
- if (child->hasTagName(colTag) || child->hasTagName(colgroupTag))
</del><ins>+ for (auto& child : elementChildren(*tableElement)) {
+ if (child.hasTagName(colTag) || child.hasTagName(colgroupTag))
</ins><span class="cx"> return true;
</span><span class="cx"> }
</span><span class="cx">
</span></span></pre></div>
<a id="trunkSourceWebCoredomChildNodeListcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/dom/ChildNodeList.cpp (160597 => 160598)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/dom/ChildNodeList.cpp        2013-12-14 17:53:05 UTC (rev 160597)
+++ trunk/Source/WebCore/dom/ChildNodeList.cpp        2013-12-14 18:05:45 UTC (rev 160598)
</span><span class="lines">@@ -94,9 +94,7 @@
</span><span class="cx"> if (!element || !m_parent.get().treeScope().containsMultipleElementsWithId(name))
</span><span class="cx"> return nullptr;
</span><span class="cx"> }
</span><del>- auto children = elementChildren(m_parent.get());
- for (auto it = children.begin(), end = children.end(); it != end; ++it) {
- auto& element = *it;
</del><ins>+ for (auto& element : elementChildren(m_parent.get())) {
</ins><span class="cx"> if (element.hasID() && element.idForStyleResolution() == name)
</span><span class="cx"> return const_cast<Element*>(&element);
</span><span class="cx"> }
</span></span></pre></div>
<a id="trunkSourceWebCoredomDocumentcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/dom/Document.cpp (160597 => 160598)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/dom/Document.cpp        2013-12-14 17:53:05 UTC (rev 160597)
+++ trunk/Source/WebCore/dom/Document.cpp        2013-12-14 18:05:45 UTC (rev 160598)
</span><span class="lines">@@ -656,13 +656,12 @@
</span><span class="cx"> {
</span><span class="cx"> ASSERT(scope);
</span><span class="cx"> ContainerNode* rootNode = scope->rootNode();
</span><del>- auto descendant = elementDescendants(*rootNode);
- for (auto element = descendant.begin(), end = descendant.end(); element != end; ++element) {
- const AtomicString& accessKey = element->fastGetAttribute(accesskeyAttr);
</del><ins>+ for (auto& element : elementDescendants(*rootNode)) {
+ const AtomicString& accessKey = element.fastGetAttribute(accesskeyAttr);
</ins><span class="cx"> if (!accessKey.isEmpty())
</span><del>- m_elementsByAccessKey.set(accessKey.impl(), &*element);
</del><ins>+ m_elementsByAccessKey.set(accessKey.impl(), &element);
</ins><span class="cx">
</span><del>- if (ShadowRoot* root = element->shadowRoot())
</del><ins>+ if (ShadowRoot* root = element.shadowRoot())
</ins><span class="cx"> buildAccessKeyMap(root);
</span><span class="cx"> }
</span><span class="cx"> }
</span><span class="lines">@@ -2579,9 +2578,8 @@
</span><span class="cx"> if (!equalIgnoringFragmentIdentifier(oldBaseURL, m_baseURL)) {
</span><span class="cx"> // Base URL change changes any relative visited links.
</span><span class="cx"> // FIXME: There are other URLs in the tree that would need to be re-evaluated on dynamic base URL change. Style should be invalidated too.
</span><del>- auto anchorDescendants = descendantsOfType<HTMLAnchorElement>(*this);
- for (auto anchor = anchorDescendants.begin(), end = anchorDescendants.end(); anchor != end; ++anchor)
- anchor->invalidateCachedVisitedLinkHash();
</del><ins>+ for (auto& anchor : descendantsOfType<HTMLAnchorElement>(*this))
+ anchor.invalidateCachedVisitedLinkHash();
</ins><span class="cx"> }
</span><span class="cx"> }
</span><span class="cx">
</span></span></pre></div>
<a id="trunkSourceWebCoredomSelectorQuerycpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/dom/SelectorQuery.cpp (160597 => 160598)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/dom/SelectorQuery.cpp        2013-12-14 17:53:05 UTC (rev 160597)
+++ trunk/Source/WebCore/dom/SelectorQuery.cpp        2013-12-14 18:05:45 UTC (rev 160598)
</span><span class="lines">@@ -165,10 +165,9 @@
</span><span class="cx"> template <typename SelectorQueryTrait>
</span><span class="cx"> static inline void elementsForLocalName(const ContainerNode& rootNode, const AtomicString& localName, typename SelectorQueryTrait::OutputType& output)
</span><span class="cx"> {
</span><del>- auto descendants = elementDescendants(const_cast<ContainerNode&>(rootNode));
- for (auto element = descendants.begin(), end = descendants.end(); element != end; ++element) {
- if (element->tagQName().localName() == localName) {
- SelectorQueryTrait::appendOutputForElement(output, &*element);
</del><ins>+ for (auto& element : elementDescendants(const_cast<ContainerNode&>(rootNode))) {
+ if (element.tagQName().localName() == localName) {
+ SelectorQueryTrait::appendOutputForElement(output, &element);
</ins><span class="cx"> if (SelectorQueryTrait::shouldOnlyMatchFirstElement)
</span><span class="cx"> return;
</span><span class="cx"> }
</span><span class="lines">@@ -178,9 +177,8 @@
</span><span class="cx"> template <typename SelectorQueryTrait>
</span><span class="cx"> static inline void anyElement(const ContainerNode& rootNode, typename SelectorQueryTrait::OutputType& output)
</span><span class="cx"> {
</span><del>- auto descendants = elementDescendants(const_cast<ContainerNode&>(rootNode));
- for (auto element = descendants.begin(), end = descendants.end(); element != end; ++element) {
- SelectorQueryTrait::appendOutputForElement(output, &*element);
</del><ins>+ for (auto& element : elementDescendants(const_cast<ContainerNode&>(rootNode))) {
+ SelectorQueryTrait::appendOutputForElement(output, &element);
</ins><span class="cx"> if (SelectorQueryTrait::shouldOnlyMatchFirstElement)
</span><span class="cx"> return;
</span><span class="cx"> }
</span><span class="lines">@@ -207,10 +205,9 @@
</span><span class="cx"> }
</span><span class="cx"> } else {
</span><span class="cx"> // Fallback: NamespaceURI is set, selectorLocalName may be starAtom.
</span><del>- auto descendants = elementDescendants(const_cast<ContainerNode&>(rootNode));
- for (auto element = descendants.begin(), end = descendants.end(); element != end; ++element) {
- if (element->namespaceURI() == selectorNamespaceURI && (selectorLocalName == starAtom || element->tagQName().localName() == selectorLocalName)) {
- SelectorQueryTrait::appendOutputForElement(output, &*element);
</del><ins>+ for (auto& element : elementDescendants(const_cast<ContainerNode&>(rootNode))) {
+ if (element.namespaceURI() == selectorNamespaceURI && (selectorLocalName == starAtom || element.tagQName().localName() == selectorLocalName)) {
+ SelectorQueryTrait::appendOutputForElement(output, &element);
</ins><span class="cx"> if (SelectorQueryTrait::shouldOnlyMatchFirstElement)
</span><span class="cx"> return;
</span><span class="cx"> }
</span><span class="lines">@@ -230,10 +227,9 @@
</span><span class="cx"> ASSERT(isSingleClassNameSelector(*selectorData.selector));
</span><span class="cx">
</span><span class="cx"> const AtomicString& className = selectorData.selector->value();
</span><del>- auto descendants = elementDescendants(const_cast<ContainerNode&>(rootNode));
- for (auto element = descendants.begin(), end = descendants.end(); element != end; ++element) {
- if (element->hasClass() && element->classNames().contains(className)) {
- SelectorQueryTrait::appendOutputForElement(output, &*element);
</del><ins>+ for (auto& element : elementDescendants(const_cast<ContainerNode&>(rootNode))) {
+ if (element.hasClass() && element.classNames().contains(className)) {
+ SelectorQueryTrait::appendOutputForElement(output, &element);
</ins><span class="cx"> if (SelectorQueryTrait::shouldOnlyMatchFirstElement)
</span><span class="cx"> return;
</span><span class="cx"> }
</span><span class="lines">@@ -245,10 +241,9 @@
</span><span class="cx"> {
</span><span class="cx"> ASSERT(m_selectors.size() == 1);
</span><span class="cx">
</span><del>- auto descendants = elementDescendants(const_cast<ContainerNode&>(rootNode));
- for (auto element = descendants.begin(), end = descendants.end(); element != end; ++element) {
- if (selectorMatches(selectorData, *element, rootNode)) {
- SelectorQueryTrait::appendOutputForElement(output, &*element);
</del><ins>+ for (auto& element : elementDescendants(const_cast<ContainerNode&>(rootNode))) {
+ if (selectorMatches(selectorData, element, rootNode)) {
+ SelectorQueryTrait::appendOutputForElement(output, &element);
</ins><span class="cx"> if (SelectorQueryTrait::shouldOnlyMatchFirstElement)
</span><span class="cx"> return;
</span><span class="cx"> }
</span><span class="lines">@@ -259,11 +254,10 @@
</span><span class="cx"> ALWAYS_INLINE void SelectorDataList::executeSingleMultiSelectorData(const ContainerNode& rootNode, typename SelectorQueryTrait::OutputType& output) const
</span><span class="cx"> {
</span><span class="cx"> unsigned selectorCount = m_selectors.size();
</span><del>- auto descendants = elementDescendants(const_cast<ContainerNode&>(rootNode));
- for (auto element = descendants.begin(), end = descendants.end(); element != end; ++element) {
</del><ins>+ for (auto& element : elementDescendants(const_cast<ContainerNode&>(rootNode))) {
</ins><span class="cx"> for (unsigned i = 0; i < selectorCount; ++i) {
</span><del>- if (selectorMatches(m_selectors[i], *element, rootNode)) {
- SelectorQueryTrait::appendOutputForElement(output, &*element);
</del><ins>+ if (selectorMatches(m_selectors[i], element, rootNode)) {
+ SelectorQueryTrait::appendOutputForElement(output, &element);
</ins><span class="cx"> if (SelectorQueryTrait::shouldOnlyMatchFirstElement)
</span><span class="cx"> return;
</span><span class="cx"> break;
</span></span></pre></div>
<a id="trunkSourceWebCoredomTreeScopecpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/dom/TreeScope.cpp (160597 => 160598)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/dom/TreeScope.cpp        2013-12-14 17:53:05 UTC (rev 160597)
+++ trunk/Source/WebCore/dom/TreeScope.cpp        2013-12-14 18:05:45 UTC (rev 160598)
</span><span class="lines">@@ -294,11 +294,10 @@
</span><span class="cx"> // Populate the map on first access.
</span><span class="cx"> m_labelsByForAttribute = adoptPtr(new DocumentOrderedMap);
</span><span class="cx">
</span><del>- auto labelDescendants = descendantsOfType<HTMLLabelElement>(*rootNode());
- for (auto label = labelDescendants.begin(), end = labelDescendants.end(); label != end; ++label) {
- const AtomicString& forValue = label->fastGetAttribute(forAttr);
</del><ins>+ for (auto& label : descendantsOfType<HTMLLabelElement>(*rootNode())) {
+ const AtomicString& forValue = label.fastGetAttribute(forAttr);
</ins><span class="cx"> if (!forValue.isEmpty())
</span><del>- addLabel(*forValue.impl(), *label);
</del><ins>+ addLabel(*forValue.impl(), label);
</ins><span class="cx"> }
</span><span class="cx"> }
</span><span class="cx">
</span><span class="lines">@@ -336,16 +335,15 @@
</span><span class="cx"> return nullptr;
</span><span class="cx"> if (Element* element = getElementById(name))
</span><span class="cx"> return element;
</span><del>- auto anchorDescendants = descendantsOfType<HTMLAnchorElement>(*rootNode());
- for (auto anchor = anchorDescendants.begin(), end = anchorDescendants.end(); anchor != end; ++anchor) {
</del><ins>+ for (auto& anchor : descendantsOfType<HTMLAnchorElement>(*rootNode())) {
</ins><span class="cx"> if (rootNode()->document().inQuirksMode()) {
</span><span class="cx"> // Quirks mode, case insensitive comparison of names.
</span><del>- if (equalIgnoringCase(anchor->name(), name))
- return &*anchor;
</del><ins>+ if (equalIgnoringCase(anchor.name(), name))
+ return &anchor;
</ins><span class="cx"> } else {
</span><span class="cx"> // Strict mode, names need to match exactly.
</span><del>- if (anchor->name() == name)
- return &*anchor;
</del><ins>+ if (anchor.name() == name)
+ return &anchor;
</ins><span class="cx"> }
</span><span class="cx"> }
</span><span class="cx"> return nullptr;
</span></span></pre></div>
<a id="trunkSourceWebCoreeditingApplyStyleCommandcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/editing/ApplyStyleCommand.cpp (160597 => 160598)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/editing/ApplyStyleCommand.cpp        2013-12-14 17:53:05 UTC (rev 160597)
+++ trunk/Source/WebCore/editing/ApplyStyleCommand.cpp        2013-12-14 18:05:45 UTC (rev 160598)
</span><span class="lines">@@ -439,10 +439,9 @@
</span><span class="cx"> // all the children of the dummy's parent
</span><span class="cx">
</span><span class="cx"> Vector<Element*> toRemove;
</span><del>- auto children = elementChildren(*dummySpanAncestor);
- for (auto child = children.begin(), end = children.end(); child != end; ++child) {
- if (isSpanWithoutAttributesOrUnstyledStyleSpan(&*child))
- toRemove.append(&*child);
</del><ins>+ for (auto& child : elementChildren(*dummySpanAncestor)) {
+ if (isSpanWithoutAttributesOrUnstyledStyleSpan(&child))
+ toRemove.append(&child);
</ins><span class="cx"> }
</span><span class="cx"> for (unsigned i = 0; i < toRemove.size(); ++i)
</span><span class="cx"> removeNodePreservingChildren(toRemove[i]);
</span></span></pre></div>
<a id="trunkSourceWebCoreeditingmarkupcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/editing/markup.cpp (160597 => 160598)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/editing/markup.cpp        2013-12-14 17:53:05 UTC (rev 160597)
+++ trunk/Source/WebCore/editing/markup.cpp        2013-12-14 18:05:45 UTC (rev 160598)
</span><span class="lines">@@ -99,15 +99,14 @@
</span><span class="cx">
</span><span class="cx"> URL parsedBaseURL(ParsedURLString, baseURL);
</span><span class="cx">
</span><del>- auto descendants = elementDescendants(*fragment);
- for (auto element = descendants.begin(), end = descendants.end(); element != end; ++element) {
- if (!element->hasAttributes())
</del><ins>+ for (auto& element : elementDescendants(*fragment)) {
+ if (!element.hasAttributes())
</ins><span class="cx"> continue;
</span><del>- unsigned length = element->attributeCount();
</del><ins>+ unsigned length = element.attributeCount();
</ins><span class="cx"> for (unsigned i = 0; i < length; i++) {
</span><del>- const Attribute& attribute = element->attributeAt(i);
- if (element->isURLAttribute(attribute) && !attribute.value().isEmpty())
- changes.append(AttributeChange(&*element, attribute.name(), URL(parsedBaseURL, attribute.value()).string()));
</del><ins>+ const Attribute& attribute = element.attributeAt(i);
+ if (element.isURLAttribute(attribute) && !attribute.value().isEmpty())
+ changes.append(AttributeChange(&element, attribute.name(), URL(parsedBaseURL, attribute.value()).string()));
</ins><span class="cx"> }
</span><span class="cx"> }
</span><span class="cx">
</span><span class="lines">@@ -892,9 +891,7 @@
</span><span class="cx"> static Vector<Ref<HTMLElement>> collectElementsToRemoveFromFragment(ContainerNode& container)
</span><span class="cx"> {
</span><span class="cx"> Vector<Ref<HTMLElement>> toRemove;
</span><del>- auto children = childrenOfType<HTMLElement>(container);
- for (auto it = children.begin(), end = children.end(); it != end; ++it) {
- HTMLElement& element = *it;
</del><ins>+ for (auto& element : childrenOfType<HTMLElement>(container)) {
</ins><span class="cx"> if (isHTMLHtmlElement(element)) {
</span><span class="cx"> toRemove.append(element);
</span><span class="cx"> collectElementsToRemoveFromFragment(element);
</span></span></pre></div>
<a id="trunkSourceWebCorehtmlHTMLAppletElementcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/html/HTMLAppletElement.cpp (160597 => 160598)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/html/HTMLAppletElement.cpp        2013-12-14 17:53:05 UTC (rev 160597)
+++ trunk/Source/WebCore/html/HTMLAppletElement.cpp        2013-12-14 18:05:45 UTC (rev 160598)
</span><span class="lines">@@ -148,13 +148,12 @@
</span><span class="cx"> paramValues.append(mayScript.string());
</span><span class="cx"> }
</span><span class="cx">
</span><del>- auto paramChildren = childrenOfType<HTMLParamElement>(*this);
- for (auto param = paramChildren.begin(), end = paramChildren.end(); param != end; ++param) {
- if (param->name().isEmpty())
</del><ins>+ for (auto& param : childrenOfType<HTMLParamElement>(*this)) {
+ if (param.name().isEmpty())
</ins><span class="cx"> continue;
</span><span class="cx">
</span><del>- paramNames.append(param->name());
- paramValues.append(param->value());
</del><ins>+ paramNames.append(param.name());
+ paramValues.append(param.value());
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> Frame* frame = document().frame();
</span></span></pre></div>
<a id="trunkSourceWebCorehtmlHTMLElementcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/html/HTMLElement.cpp (160597 => 160598)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/html/HTMLElement.cpp        2013-12-14 17:53:05 UTC (rev 160597)
+++ trunk/Source/WebCore/html/HTMLElement.cpp        2013-12-14 18:05:45 UTC (rev 160598)
</span><span class="lines">@@ -744,9 +744,8 @@
</span><span class="cx">
</span><span class="cx"> bool HTMLElement::translate() const
</span><span class="cx"> {
</span><del>- auto lineage = lineageOfType<HTMLElement>(*this);
- for (auto element = lineage.begin(), end = lineage.end(); element != end; ++element) {
- TranslateAttributeMode mode = element->translateAttributeMode();
</del><ins>+ for (auto& element : lineageOfType<HTMLElement>(*this)) {
+ TranslateAttributeMode mode = element.translateAttributeMode();
</ins><span class="cx"> if (mode == TranslateAttributeInherit)
</span><span class="cx"> continue;
</span><span class="cx"> ASSERT(mode == TranslateAttributeYes || mode == TranslateAttributeNo);
</span><span class="lines">@@ -793,9 +792,9 @@
</span><span class="cx"> return HTMLFormElement::findClosestFormAncestor(*this);
</span><span class="cx"> }
</span><span class="cx">
</span><del>-static inline bool elementAffectsDirectionality(const Node* node)
</del><ins>+static inline bool elementAffectsDirectionality(const Node& node)
</ins><span class="cx"> {
</span><del>- return node->isHTMLElement() && (node->hasTagName(bdiTag) || toHTMLElement(node)->hasAttribute(dirAttr));
</del><ins>+ return node.isHTMLElement() && (node.hasTagName(bdiTag) || toHTMLElement(node).hasAttribute(dirAttr));
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> static void setHasDirAutoFlagRecursively(Node* firstNode, bool flag, Node* lastNode = nullptr)
</span><span class="lines">@@ -808,7 +807,7 @@
</span><span class="cx"> if (node->selfOrAncestorHasDirAutoAttribute() == flag)
</span><span class="cx"> return;
</span><span class="cx">
</span><del>- if (elementAffectsDirectionality(node)) {
</del><ins>+ if (elementAffectsDirectionality(*node)) {
</ins><span class="cx"> if (node == lastNode)
</span><span class="cx"> return;
</span><span class="cx"> node = NodeTraversal::nextSkippingChildren(node, firstNode);
</span><span class="lines">@@ -908,10 +907,9 @@
</span><span class="cx"> setHasDirAutoFlagRecursively(child, false);
</span><span class="cx"> if (!renderer() || renderer()->style().direction() == textDirection)
</span><span class="cx"> return;
</span><del>- auto lineage = elementLineage(this);
- for (auto elementToAdjust = lineage.begin(), end = lineage.end(); elementToAdjust != end; ++elementToAdjust) {
- if (elementAffectsDirectionality(&*elementToAdjust)) {
- elementToAdjust->setNeedsStyleRecalc();
</del><ins>+ for (auto& elementToAdjust : elementLineage(this)) {
+ if (elementAffectsDirectionality(elementToAdjust)) {
+ elementToAdjust.setNeedsStyleRecalc();
</ins><span class="cx"> return;
</span><span class="cx"> }
</span><span class="cx"> }
</span><span class="lines">@@ -932,7 +930,7 @@
</span><span class="cx"> if (document().renderView() && (changeType == ElementRemoved || changeType == TextRemoved)) {
</span><span class="cx"> Node* node = beforeChange ? beforeChange->nextSibling() : nullptr;
</span><span class="cx"> for (; node; node = node->nextSibling()) {
</span><del>- if (elementAffectsDirectionality(node))
</del><ins>+ if (elementAffectsDirectionality(*node))
</ins><span class="cx"> continue;
</span><span class="cx">
</span><span class="cx"> setHasDirAutoFlagRecursively(node, false);
</span><span class="lines">@@ -946,15 +944,14 @@
</span><span class="cx"> if (beforeChange)
</span><span class="cx"> oldMarkedNode = changeType == ElementInserted ? ElementTraversal::nextSibling(beforeChange) : beforeChange->nextSibling();
</span><span class="cx">
</span><del>- while (oldMarkedNode && elementAffectsDirectionality(oldMarkedNode))
</del><ins>+ while (oldMarkedNode && elementAffectsDirectionality(*oldMarkedNode))
</ins><span class="cx"> oldMarkedNode = oldMarkedNode->nextSibling();
</span><span class="cx"> if (oldMarkedNode)
</span><span class="cx"> setHasDirAutoFlagRecursively(oldMarkedNode, false);
</span><span class="cx">
</span><del>- auto lineage = lineageOfType<HTMLElement>(*this);
- for (auto elementToAdjust = lineage.begin(), end = lineage.end(); elementToAdjust != end; ++elementToAdjust) {
- if (elementAffectsDirectionality(&*elementToAdjust)) {
- elementToAdjust->calculateAndAdjustDirectionality();
</del><ins>+ for (auto& elementToAdjust : lineageOfType<HTMLElement>(*this)) {
+ if (elementAffectsDirectionality(elementToAdjust)) {
+ elementToAdjust.calculateAndAdjustDirectionality();
</ins><span class="cx"> return;
</span><span class="cx"> }
</span><span class="cx"> }
</span></span></pre></div>
<a id="trunkSourceWebCorehtmlHTMLFieldSetElementcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/html/HTMLFieldSetElement.cpp (160597 => 160598)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/html/HTMLFieldSetElement.cpp        2013-12-14 17:53:05 UTC (rev 160597)
+++ trunk/Source/WebCore/html/HTMLFieldSetElement.cpp        2013-12-14 18:05:45 UTC (rev 160598)
</span><span class="lines">@@ -51,9 +51,8 @@
</span><span class="cx">
</span><span class="cx"> void HTMLFieldSetElement::invalidateDisabledStateUnder(Element* base)
</span><span class="cx"> {
</span><del>- auto formControlDescendants = descendantsOfType<HTMLFormControlElement>(*base);
- for (auto control = formControlDescendants.begin(), end = formControlDescendants.end(); control != end; ++control)
- control->ancestorDisabledStateWasChanged();
</del><ins>+ for (auto& control : descendantsOfType<HTMLFormControlElement>(*base))
+ control.ancestorDisabledStateWasChanged();
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> void HTMLFieldSetElement::disabledAttributeChanged()
</span><span class="lines">@@ -67,9 +66,8 @@
</span><span class="cx"> {
</span><span class="cx"> HTMLFormControlElement::childrenChanged(change);
</span><span class="cx">
</span><del>- auto legendChildren = childrenOfType<HTMLLegendElement>(*this);
- for (auto legend = legendChildren.begin(), end = legendChildren.end(); legend != end; ++legend)
- invalidateDisabledStateUnder(&*legend);
</del><ins>+ for (auto& legend : childrenOfType<HTMLLegendElement>(*this))
+ invalidateDisabledStateUnder(&legend);
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> bool HTMLFieldSetElement::supportsFocus() const
</span><span class="lines">@@ -108,12 +106,11 @@
</span><span class="cx">
</span><span class="cx"> m_associatedElements.clear();
</span><span class="cx">
</span><del>- auto descendants = elementDescendants(const_cast<HTMLFieldSetElement&>(*this));
- for (auto element = descendants.begin(), end = descendants.end(); element != end; ++element) {
- if (element->hasTagName(objectTag))
- m_associatedElements.append(&toHTMLObjectElement(*element));
- else if (element->isFormControlElement())
- m_associatedElements.append(&toHTMLFormControlElement(*element));
</del><ins>+ for (auto& element : elementDescendants(const_cast<HTMLFieldSetElement&>(*this))) {
+ if (element.hasTagName(objectTag))
+ m_associatedElements.append(&toHTMLObjectElement(element));
+ else if (element.isFormControlElement())
+ m_associatedElements.append(&toHTMLFormControlElement(element));
</ins><span class="cx"> }
</span><span class="cx"> }
</span><span class="cx">
</span></span></pre></div>
<a id="trunkSourceWebCorehtmlHTMLFormElementcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/html/HTMLFormElement.cpp (160597 => 160598)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/html/HTMLFormElement.cpp        2013-12-14 17:53:05 UTC (rev 160597)
+++ trunk/Source/WebCore/html/HTMLFormElement.cpp        2013-12-14 18:05:45 UTC (rev 160598)
</span><span class="lines">@@ -475,8 +475,7 @@
</span><span class="cx"> return currentAssociatedElementsAfterIndex;
</span><span class="cx">
</span><span class="cx"> unsigned i = m_associatedElementsBeforeIndex;
</span><del>- for (auto it = descendants.begin(); it != end; ++it) {
- HTMLElement& element = *it;
</del><ins>+ for (auto& element : descendants) {
</ins><span class="cx"> if (&element == &associatedHTMLElement)
</span><span class="cx"> return i;
</span><span class="cx"> if (!isHTMLFormControlElement(element) && !isHTMLObjectElement(element))
</span></span></pre></div>
<a id="trunkSourceWebCorehtmlHTMLLabelElementcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/html/HTMLLabelElement.cpp (160597 => 160598)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/html/HTMLLabelElement.cpp        2013-12-14 17:53:05 UTC (rev 160597)
+++ trunk/Source/WebCore/html/HTMLLabelElement.cpp        2013-12-14 18:05:45 UTC (rev 160598)
</span><span class="lines">@@ -67,12 +67,11 @@
</span><span class="cx"> // Search the children and descendants of the label element for a form element.
</span><span class="cx"> // per http://dev.w3.org/html5/spec/Overview.html#the-label-element
</span><span class="cx"> // the form element must be "labelable form-associated element".
</span><del>- auto labelableDescendants = descendantsOfType<LabelableElement>(*this);
- for (auto labelableElement = labelableDescendants.begin(), end = labelableDescendants.end(); labelableElement != end; ++labelableElement) {
- if (labelableElement->supportLabels())
- return &*labelableElement;
</del><ins>+ for (auto& labelableElement : descendantsOfType<LabelableElement>(*this)) {
+ if (labelableElement.supportLabels())
+ return &labelableElement;
</ins><span class="cx"> }
</span><del>- return 0;
</del><ins>+ return nullptr;
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> // Find the first element whose id is controlId. If it is found and it is a labelable form control,
</span></span></pre></div>
<a id="trunkSourceWebCorehtmlHTMLMapElementcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/html/HTMLMapElement.cpp (160597 => 160598)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/html/HTMLMapElement.cpp        2013-12-14 17:53:05 UTC (rev 160597)
+++ trunk/Source/WebCore/html/HTMLMapElement.cpp        2013-12-14 18:05:45 UTC (rev 160598)
</span><span class="lines">@@ -59,12 +59,11 @@
</span><span class="cx"> {
</span><span class="cx"> HTMLAreaElement* defaultArea = 0;
</span><span class="cx">
</span><del>- auto areaDescendants = descendantsOfType<HTMLAreaElement>(*this);
- for (auto area = areaDescendants.begin(), end = areaDescendants.end(); area != end; ++area) {
- if (area->isDefault()) {
</del><ins>+ for (auto& area : descendantsOfType<HTMLAreaElement>(*this)) {
+ if (area.isDefault()) {
</ins><span class="cx"> if (!defaultArea)
</span><del>- defaultArea = &*area;
- } else if (area->mapMouseEvent(location, size, result))
</del><ins>+ defaultArea = &area;
+ } else if (area.mapMouseEvent(location, size, result))
</ins><span class="cx"> return true;
</span><span class="cx"> }
</span><span class="cx">
</span></span></pre></div>
<a id="trunkSourceWebCorehtmlHTMLMediaElementcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/html/HTMLMediaElement.cpp (160597 => 160598)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/html/HTMLMediaElement.cpp        2013-12-14 17:53:05 UTC (rev 160597)
+++ trunk/Source/WebCore/html/HTMLMediaElement.cpp        2013-12-14 18:05:45 UTC (rev 160598)
</span><span class="lines">@@ -1473,10 +1473,9 @@
</span><span class="cx"> bool trackIsLoaded = true;
</span><span class="cx"> if (track->trackType() == TextTrack::TrackElement) {
</span><span class="cx"> trackIsLoaded = false;
</span><del>- auto trackChildren = childrenOfType<HTMLTrackElement>(*this);
- for (auto trackElement = trackChildren.begin(), end = trackChildren.end(); trackElement != end; ++trackElement) {
- if (trackElement->track() == track) {
- if (trackElement->readyState() == HTMLTrackElement::LOADING || trackElement->readyState() == HTMLTrackElement::LOADED)
</del><ins>+ for (auto& trackElement : childrenOfType<HTMLTrackElement>(*this)) {
+ if (trackElement.track() == track) {
+ if (trackElement.readyState() == HTMLTrackElement::LOADING || trackElement.readyState() == HTMLTrackElement::LOADED)
</ins><span class="cx"> trackIsLoaded = true;
</span><span class="cx"> break;
</span><span class="cx"> }
</span><span class="lines">@@ -1717,9 +1716,8 @@
</span><span class="cx"> LOG(Media, "HTMLMediaElement::cancelPendingEventsAndCallbacks");
</span><span class="cx"> m_asyncEventQueue.cancelAllEvents();
</span><span class="cx">
</span><del>- auto sourceChildren = childrenOfType<HTMLSourceElement>(*this);
- for (auto source = sourceChildren.begin(), end = sourceChildren.end(); source != end; ++source)
- source->cancelPendingErrorEvent();
</del><ins>+ for (auto& source : childrenOfType<HTMLSourceElement>(*this))
+ source.cancelPendingErrorEvent();
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> Document* HTMLMediaElement::mediaPlayerOwningDocument()
</span></span></pre></div>
<a id="trunkSourceWebCorehtmlHTMLObjectElementcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/html/HTMLObjectElement.cpp (160597 => 160598)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/html/HTMLObjectElement.cpp        2013-12-14 17:53:05 UTC (rev 160597)
+++ trunk/Source/WebCore/html/HTMLObjectElement.cpp        2013-12-14 18:05:45 UTC (rev 160598)
</span><span class="lines">@@ -154,22 +154,21 @@
</span><span class="cx">
</span><span class="cx"> // Scan the PARAM children and store their name/value pairs.
</span><span class="cx"> // Get the URL and type from the params if we don't already have them.
</span><del>- auto paramChildren = childrenOfType<HTMLParamElement>(*this);
- for (auto param = paramChildren.begin(), end = paramChildren.end(); param != end; ++param) {
- String name = param->name();
</del><ins>+ for (auto& param : childrenOfType<HTMLParamElement>(*this)) {
+ String name = param.name();
</ins><span class="cx"> if (name.isEmpty())
</span><span class="cx"> continue;
</span><span class="cx">
</span><span class="cx"> uniqueParamNames.add(name.impl());
</span><del>- paramNames.append(param->name());
- paramValues.append(param->value());
</del><ins>+ paramNames.append(param.name());
+ paramValues.append(param.value());
</ins><span class="cx">
</span><span class="cx"> // FIXME: url adjustment does not belong in this function.
</span><span class="cx"> if (url.isEmpty() && urlParameter.isEmpty() && (equalIgnoringCase(name, "src") || equalIgnoringCase(name, "movie") || equalIgnoringCase(name, "code") || equalIgnoringCase(name, "url")))
</span><del>- urlParameter = stripLeadingAndTrailingHTMLSpaces(param->value());
</del><ins>+ urlParameter = stripLeadingAndTrailingHTMLSpaces(param.value());
</ins><span class="cx"> // FIXME: serviceType calculation does not belong in this function.
</span><span class="cx"> if (serviceType.isEmpty() && equalIgnoringCase(name, "type")) {
</span><del>- serviceType = param->value();
</del><ins>+ serviceType = param.value();
</ins><span class="cx"> size_t pos = serviceType.find(";");
</span><span class="cx"> if (pos != notFound)
</span><span class="cx"> serviceType = serviceType.left(pos);
</span><span class="lines">@@ -445,14 +444,13 @@
</span><span class="cx"> if (MIMETypeRegistry::isJavaAppletMIMEType(getAttribute(typeAttr)))
</span><span class="cx"> return true;
</span><span class="cx">
</span><del>- auto children = elementChildren(*this);
- for (auto child = children.begin(), end = children.end(); child != end; ++child) {
- if (child->hasTagName(paramTag) && equalIgnoringCase(child->getNameAttribute(), "type")
- && MIMETypeRegistry::isJavaAppletMIMEType(child->getAttribute(valueAttr).string()))
</del><ins>+ for (auto& child : elementChildren(*this)) {
+ if (child.hasTagName(paramTag) && equalIgnoringCase(child.getNameAttribute(), "type")
+ && MIMETypeRegistry::isJavaAppletMIMEType(child.getAttribute(valueAttr).string()))
</ins><span class="cx"> return true;
</span><del>- if (child->hasTagName(objectTag) && static_cast<const HTMLObjectElement&>(*child).containsJavaApplet())
</del><ins>+ if (child.hasTagName(objectTag) && toHTMLObjectElement(child).containsJavaApplet())
</ins><span class="cx"> return true;
</span><del>- if (child->hasTagName(appletTag))
</del><ins>+ if (child.hasTagName(appletTag))
</ins><span class="cx"> return true;
</span><span class="cx"> }
</span><span class="cx">
</span></span></pre></div>
<a id="trunkSourceWebCoreloaderPlaceholderDocumentcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/loader/PlaceholderDocument.cpp (160597 => 160598)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/loader/PlaceholderDocument.cpp        2013-12-14 17:53:05 UTC (rev 160597)
+++ trunk/Source/WebCore/loader/PlaceholderDocument.cpp        2013-12-14 18:05:45 UTC (rev 160598)
</span><span class="lines">@@ -34,9 +34,8 @@
</span><span class="cx"> {
</span><span class="cx"> ASSERT(!attached());
</span><span class="cx">
</span><del>- auto children = elementChildren(*this);
- for (auto child = children.begin(), end = children.end(); child != end; ++child)
- Style::attachRenderTree(*child);
</del><ins>+ for (auto& child : elementChildren(*this))
+ Style::attachRenderTree(child);
</ins><span class="cx">
</span><span class="cx"> setAttached(true);
</span><span class="cx"> }
</span></span></pre></div>
<a id="trunkSourceWebCorerenderingFilterEffectRenderercpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/rendering/FilterEffectRenderer.cpp (160597 => 160598)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/rendering/FilterEffectRenderer.cpp        2013-12-14 17:53:05 UTC (rev 160597)
+++ trunk/Source/WebCore/rendering/FilterEffectRenderer.cpp        2013-12-14 18:05:45 UTC (rev 160598)
</span><span class="lines">@@ -161,15 +161,13 @@
</span><span class="cx"> // This may need a spec clarification.
</span><span class="cx"> auto builder = std::make_unique<SVGFilterBuilder>(previousEffect, SourceAlpha::create(this));
</span><span class="cx">
</span><del>- auto attributesChildren = childrenOfType<SVGFilterPrimitiveStandardAttributes>(*filter);
- for (auto it = attributesChildren.begin(), end = attributesChildren.end(); it != end; ++it) {
- SVGFilterPrimitiveStandardAttributes* effectElement = &*it;
- effect = effectElement->build(builder.get(), this);
</del><ins>+ for (auto& effectElement : childrenOfType<SVGFilterPrimitiveStandardAttributes>(*filter)) {
+ effect = effectElement.build(builder.get(), this);
</ins><span class="cx"> if (!effect)
</span><span class="cx"> continue;
</span><span class="cx">
</span><del>- effectElement->setStandardAttributes(effect.get());
- builder->add(effectElement->result(), effect);
</del><ins>+ effectElement.setStandardAttributes(effect.get());
+ builder->add(effectElement.result(), effect);
</ins><span class="cx"> m_effects.append(effect);
</span><span class="cx"> }
</span><span class="cx"> return effect;
</span></span></pre></div>
<a id="trunkSourceWebCorerenderingRenderBlockcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/rendering/RenderBlock.cpp (160597 => 160598)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/rendering/RenderBlock.cpp        2013-12-14 17:53:05 UTC (rev 160597)
+++ trunk/Source/WebCore/rendering/RenderBlock.cpp        2013-12-14 18:05:45 UTC (rev 160598)
</span><span class="lines">@@ -1455,9 +1455,8 @@
</span><span class="cx"> return;
</span><span class="cx"> }
</span><span class="cx">
</span><del>- auto blockChildren = childrenOfType<RenderBlock>(*this);
- for (auto childBlock = blockChildren.begin(), end = blockChildren.end(); childBlock != end; ++childBlock)
- childBlock->markShapeInsideDescendantsForLayout();
</del><ins>+ for (auto& childBlock : childrenOfType<RenderBlock>(*this))
+ childBlock.markShapeInsideDescendantsForLayout();
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> ShapeInsideInfo* RenderBlock::layoutShapeInsideInfo() const
</span></span></pre></div>
<a id="trunkSourceWebCorerenderingRenderBlockFlowcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/rendering/RenderBlockFlow.cpp (160597 => 160598)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/rendering/RenderBlockFlow.cpp        2013-12-14 17:53:05 UTC (rev 160597)
+++ trunk/Source/WebCore/rendering/RenderBlockFlow.cpp        2013-12-14 18:05:45 UTC (rev 160598)
</span><span class="lines">@@ -1774,15 +1774,14 @@
</span><span class="cx"> RenderBlockFlow* parentBlock = this;
</span><span class="cx"> const FloatingObjectSet& floatingObjectSet = m_floatingObjects->set();
</span><span class="cx">
</span><del>- auto ancestors = ancestorsOfType<RenderBlockFlow>(*this);
- for (auto ancestor = ancestors.begin(), end = ancestors.end(); ancestor != end; ++ancestor) {
- if (ancestor->isRenderView())
</del><ins>+ for (auto& ancestor : ancestorsOfType<RenderBlockFlow>(*this)) {
+ if (ancestor.isRenderView())
</ins><span class="cx"> break;
</span><del>- if (ancestor->hasOverhangingFloats()) {
</del><ins>+ if (ancestor.hasOverhangingFloats()) {
</ins><span class="cx"> for (auto it = floatingObjectSet.begin(), end = floatingObjectSet.end(); it != end; ++it) {
</span><span class="cx"> RenderBox& renderer = (*it)->renderer();
</span><del>- if (ancestor->hasOverhangingFloat(renderer)) {
- parentBlock = &*ancestor;
</del><ins>+ if (ancestor.hasOverhangingFloat(renderer)) {
+ parentBlock = &ancestor;
</ins><span class="cx"> break;
</span><span class="cx"> }
</span><span class="cx"> }
</span></span></pre></div>
<a id="trunkSourceWebCorerenderingRenderBoxcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/rendering/RenderBox.cpp (160597 => 160598)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/rendering/RenderBox.cpp        2013-12-14 17:53:05 UTC (rev 160597)
+++ trunk/Source/WebCore/rendering/RenderBox.cpp        2013-12-14 18:05:45 UTC (rev 160598)
</span><span class="lines">@@ -234,12 +234,11 @@
</span><span class="cx"> {
</span><span class="cx"> ASSERT(isFloating());
</span><span class="cx"> RenderBlockFlow* parentBlock = nullptr;
</span><del>- auto ancestors = ancestorsOfType<RenderBlockFlow>(*this);
- for (auto ancestor = ancestors.begin(), end = ancestors.end(); ancestor != end; ++ancestor) {
- if (ancestor->isRenderView())
</del><ins>+ for (auto& ancestor : ancestorsOfType<RenderBlockFlow>(*this)) {
+ if (ancestor.isRenderView())
</ins><span class="cx"> break;
</span><del>- if (!parentBlock || ancestor->containsFloat(*this))
- parentBlock = &*ancestor;
</del><ins>+ if (!parentBlock || ancestor.containsFloat(*this))
+ parentBlock = &ancestor;
</ins><span class="cx"> }
</span><span class="cx"> return parentBlock;
</span><span class="cx"> }
</span><span class="lines">@@ -1330,9 +1329,7 @@
</span><span class="cx"> {
</span><span class="cx"> if (!maxDepthToTest)
</span><span class="cx"> return false;
</span><del>- auto boxChildren = childrenOfType<RenderBox>(*this);
- for (auto child = boxChildren.begin(), end = boxChildren.end(); child != end; ++child) {
- const RenderBox& childBox = *child;
</del><ins>+ for (auto& childBox : childrenOfType<RenderBox>(*this)) {
</ins><span class="cx"> if (!isCandidateForOpaquenessTest(childBox))
</span><span class="cx"> continue;
</span><span class="cx"> LayoutPoint childLocation = childBox.location();
</span></span></pre></div>
<a id="trunkSourceWebCorerenderingRenderElementcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/rendering/RenderElement.cpp (160597 => 160598)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/rendering/RenderElement.cpp        2013-12-14 17:53:05 UTC (rev 160597)
+++ trunk/Source/WebCore/rendering/RenderElement.cpp        2013-12-14 18:05:45 UTC (rev 160598)
</span><span class="lines">@@ -302,11 +302,10 @@
</span><span class="cx">
</span><span class="cx"> inline bool RenderElement::hasImmediateNonWhitespaceTextChildOrBorderOrOutline() const
</span><span class="cx"> {
</span><del>- auto children = childrenOfType<RenderObject>(*this);
- for (auto child = children.begin(), end = children.end(); child != end; ++child) {
- if (child->isText() && !toRenderText(*child).isAllCollapsibleWhitespace())
</del><ins>+ for (auto& child : childrenOfType<RenderObject>(*this)) {
+ if (child.isText() && !toRenderText(child).isAllCollapsibleWhitespace())
</ins><span class="cx"> return true;
</span><del>- if (child->style().hasOutline() || child->style().hasBorder())
</del><ins>+ if (child.style().hasOutline() || child.style().hasBorder())
</ins><span class="cx"> return true;
</span><span class="cx"> }
</span><span class="cx"> return false;
</span><span class="lines">@@ -439,9 +438,8 @@
</span><span class="cx"> styleDidChange(diff, &oldStyle.get());
</span><span class="cx">
</span><span class="cx"> // Text renderers use their parent style. Notify them about the change.
</span><del>- auto textChildren = childrenOfType<RenderText>(*this);
- for (auto child = textChildren.begin(), end = textChildren.end(); child != end; ++child)
- child->styleDidChange(diff, &oldStyle.get());
</del><ins>+ for (auto& child : childrenOfType<RenderText>(*this))
+ child.styleDidChange(diff, &oldStyle.get());
</ins><span class="cx">
</span><span class="cx"> // FIXME: |this| might be destroyed here. This can currently happen for a RenderTextFragment when
</span><span class="cx"> // its first-letter block gets an update in RenderTextFragment::styleDidChange. For RenderTextFragment(s),
</span><span class="lines">@@ -678,9 +676,8 @@
</span><span class="cx"> return;
</span><span class="cx"> }
</span><span class="cx">
</span><del>- auto children = childrenOfType<RenderElement>(renderer);
- for (auto child = children.begin(), end = children.end(); child != end; ++child)
- addLayers(*child, parentLayer, newObject, beforeChild);
</del><ins>+ for (auto& child : childrenOfType<RenderElement>(renderer))
+ addLayers(child, parentLayer, newObject, beforeChild);
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> void RenderElement::addLayers(RenderLayer* parentLayer)
</span><span class="lines">@@ -703,9 +700,8 @@
</span><span class="cx"> return;
</span><span class="cx"> }
</span><span class="cx">
</span><del>- auto children = childrenOfType<RenderElement>(*this);
- for (auto child = children.begin(), end = children.end(); child != end; ++child)
- child->removeLayers(parentLayer);
</del><ins>+ for (auto& child : childrenOfType<RenderElement>(*this))
+ child.removeLayers(parentLayer);
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> void RenderElement::moveLayers(RenderLayer* oldParent, RenderLayer* newParent)
</span><span class="lines">@@ -722,9 +718,8 @@
</span><span class="cx"> return;
</span><span class="cx"> }
</span><span class="cx">
</span><del>- auto children = childrenOfType<RenderElement>(*this);
- for (auto child = children.begin(), end = children.end(); child != end; ++child)
- child->moveLayers(oldParent, newParent);
</del><ins>+ for (auto& child : childrenOfType<RenderElement>(*this))
+ child.moveLayers(oldParent, newParent);
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> RenderLayer* RenderElement::findNextLayer(RenderLayer* parentLayer, RenderObject* startPoint, bool checkParent)
</span><span class="lines">@@ -780,9 +775,7 @@
</span><span class="cx"> void RenderElement::propagateStyleToAnonymousChildren(StylePropagationType propagationType)
</span><span class="cx"> {
</span><span class="cx"> // FIXME: We could save this call when the change only affected non-inherited properties.
</span><del>- auto children = childrenOfType<RenderElement>(*this);
- for (auto child = children.begin(), end = children.end(); child != end; ++child) {
- RenderElement& elementChild = *child;
</del><ins>+ for (auto& elementChild : childrenOfType<RenderElement>(*this)) {
</ins><span class="cx"> if (!elementChild.isAnonymous() || elementChild.style().styleType() != NOPSEUDO)
</span><span class="cx"> continue;
</span><span class="cx">
</span></span></pre></div>
<a id="trunkSourceWebCorerenderingRenderFrameSetcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/rendering/RenderFrameSet.cpp (160597 => 160598)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/rendering/RenderFrameSet.cpp        2013-12-14 17:53:05 UTC (rev 160597)
+++ trunk/Source/WebCore/rendering/RenderFrameSet.cpp        2013-12-14 18:05:45 UTC (rev 160598)
</span><span class="lines">@@ -714,10 +714,9 @@
</span><span class="cx"> void RenderFrameSet::setIsResizing(bool isResizing)
</span><span class="cx"> {
</span><span class="cx"> m_isResizing = isResizing;
</span><del>- auto ancestors = ancestorsOfType<RenderFrameSet>(*this);
- for (auto ancestor = ancestors.begin(), end = ancestors.end(); ancestor != end; ++ancestor)
- ancestor->m_isChildResizing = isResizing;
- frame().eventHandler().setResizingFrameSet(isResizing ? &frameSetElement() : 0);
</del><ins>+ for (auto& ancestor : ancestorsOfType<RenderFrameSet>(*this))
+ ancestor.m_isChildResizing = isResizing;
+ frame().eventHandler().setResizingFrameSet(isResizing ? &frameSetElement() : nullptr);
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> bool RenderFrameSet::isResizingRow() const
</span></span></pre></div>
<a id="trunkSourceWebCorerenderingRenderInlinecpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/rendering/RenderInline.cpp (160597 => 160598)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/rendering/RenderInline.cpp        2013-12-14 17:53:05 UTC (rev 160597)
+++ trunk/Source/WebCore/rendering/RenderInline.cpp        2013-12-14 18:05:45 UTC (rev 160598)
</span><span class="lines">@@ -1079,9 +1079,8 @@
</span><span class="cx"> cb->computeRectForRepaint(repaintContainer, repaintRect);
</span><span class="cx">
</span><span class="cx"> if (outlineSize) {
</span><del>- auto children = childrenOfType<RenderElement>(*this);
- for (auto child = children.begin(), end = children.end(); child != end; ++child)
- repaintRect.unite(child->rectWithOutlineForRepaint(repaintContainer, outlineSize));
</del><ins>+ for (auto& child : childrenOfType<RenderElement>(*this))
+ repaintRect.unite(child.rectWithOutlineForRepaint(repaintContainer, outlineSize));
</ins><span class="cx">
</span><span class="cx"> if (RenderBoxModelObject* continuation = this->continuation()) {
</span><span class="cx"> if (!continuation->isInline() && continuation->parent())
</span><span class="lines">@@ -1095,9 +1094,8 @@
</span><span class="cx"> LayoutRect RenderInline::rectWithOutlineForRepaint(const RenderLayerModelObject* repaintContainer, LayoutUnit outlineWidth) const
</span><span class="cx"> {
</span><span class="cx"> LayoutRect r(RenderBoxModelObject::rectWithOutlineForRepaint(repaintContainer, outlineWidth));
</span><del>- auto children = childrenOfType<RenderElement>(*this);
- for (auto child = children.begin(), end = children.end(); child != end; ++child)
- r.unite(child->rectWithOutlineForRepaint(repaintContainer, outlineWidth));
</del><ins>+ for (auto& child : childrenOfType<RenderElement>(*this))
+ r.unite(child.rectWithOutlineForRepaint(repaintContainer, outlineWidth));
</ins><span class="cx"> return r;
</span><span class="cx"> }
</span><span class="cx">
</span><span class="lines">@@ -1433,17 +1431,16 @@
</span><span class="cx"> AbsoluteRectsGeneratorContext context(rects, additionalOffset);
</span><span class="cx"> generateLineBoxRects(context);
</span><span class="cx">
</span><del>- auto children = childrenOfType<RenderElement>(*this);
- for (auto child = children.begin(), end = children.end(); child != end; ++child) {
- if (child->isListMarker())
</del><ins>+ for (auto& child : childrenOfType<RenderElement>(*this)) {
+ if (child.isListMarker())
</ins><span class="cx"> continue;
</span><span class="cx"> FloatPoint pos(additionalOffset);
</span><span class="cx"> // FIXME: This doesn't work correctly with transforms.
</span><del>- if (child->hasLayer())
- pos = child->localToContainerPoint(FloatPoint(), paintContainer);
- else if (child->isBox())
- pos.move(toRenderBox(*child).locationOffset());
- child->addFocusRingRects(rects, flooredIntPoint(pos), paintContainer);
</del><ins>+ if (child.hasLayer())
+ pos = child.localToContainerPoint(FloatPoint(), paintContainer);
+ else if (child.isBox())
+ pos.move(toRenderBox(child).locationOffset());
+ child.addFocusRingRects(rects, flooredIntPoint(pos), paintContainer);
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> if (RenderBoxModelObject* continuation = this->continuation()) {
</span></span></pre></div>
<a id="trunkSourceWebCorerenderingRenderTablecpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/rendering/RenderTable.cpp (160597 => 160598)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/rendering/RenderTable.cpp        2013-12-14 17:53:05 UTC (rev 160597)
+++ trunk/Source/WebCore/rendering/RenderTable.cpp        2013-12-14 18:05:45 UTC (rev 160598)
</span><span class="lines">@@ -448,10 +448,9 @@
</span><span class="cx">
</span><span class="cx"> bool collapsing = collapseBorders();
</span><span class="cx">
</span><del>- auto children = childrenOfType<RenderElement>(*this);
- for (auto child = children.begin(), end = children.end(); child != end; ++child) {
- if (child->isTableSection()) {
- RenderTableSection& section = toRenderTableSection(*child);
</del><ins>+ for (auto& child : childrenOfType<RenderElement>(*this)) {
+ if (child.isTableSection()) {
+ RenderTableSection& section = toRenderTableSection(child);
</ins><span class="cx"> if (m_columnLogicalWidthChanged)
</span><span class="cx"> section.setChildNeedsLayout(MarkOnlyThis);
</span><span class="cx"> section.layoutIfNeeded();
</span><span class="lines">@@ -459,9 +458,9 @@
</span><span class="cx"> if (collapsing)
</span><span class="cx"> section.recalcOuterBorder();
</span><span class="cx"> ASSERT(!section.needsLayout());
</span><del>- } else if (child->isRenderTableCol()) {
- toRenderTableCol(*child).layoutIfNeeded();
- ASSERT(!child->needsLayout());
</del><ins>+ } else if (child.isRenderTableCol()) {
+ toRenderTableCol(child).layoutIfNeeded();
+ ASSERT(!child.needsLayout());
</ins><span class="cx"> }
</span><span class="cx"> }
</span><span class="cx">
</span><span class="lines">@@ -586,9 +585,8 @@
</span><span class="cx"> m_collapsedBordersValid = true;
</span><span class="cx"> m_collapsedBorders.clear();
</span><span class="cx">
</span><del>- auto sections = childrenOfType<RenderTableSection>(*this);
- for (auto section = sections.begin(), end = sections.end(); section != end; ++section) {
- for (RenderTableRow* row = section->firstRow(); row; row = row->nextRow()) {
</del><ins>+ for (auto& section : childrenOfType<RenderTableSection>(*this)) {
+ for (RenderTableRow* row = section.firstRow(); row; row = row->nextRow()) {
</ins><span class="cx"> for (RenderTableCell* cell = row->firstCell(); cell; cell = cell->nextCell()) {
</span><span class="cx"> ASSERT(cell->table() == this);
</span><span class="cx"> cell->collectBorderValues(m_collapsedBorders);
</span><span class="lines">@@ -669,9 +667,7 @@
</span><span class="cx"> info.phase = paintPhase;
</span><span class="cx"> info.updateSubtreePaintRootForChildren(this);
</span><span class="cx">
</span><del>- auto boxChildren = childrenOfType<RenderBox>(*this);
- for (auto child = boxChildren.begin(), end = boxChildren.end(); child != end; ++child) {
- RenderBox& box = *child;
</del><ins>+ for (auto& box : childrenOfType<RenderBox>(*this)) {
</ins><span class="cx"> if (!box.hasSelfPaintingLayer() && (box.isTableSection() || box.isTableCaption())) {
</span><span class="cx"> LayoutPoint childPoint = flipForWritingModeForChild(&box, paintOffset);
</span><span class="cx"> box.paint(info, childPoint);
</span><span class="lines">@@ -808,12 +804,11 @@
</span><span class="cx">
</span><span class="cx"> // Propagate the change in our columns representation to the sections that don't need
</span><span class="cx"> // cell recalc. If they do, they will be synced up directly with m_columns later.
</span><del>- auto sections = childrenOfType<RenderTableSection>(*this);
- for (auto section = sections.begin(), end = sections.end(); section != end; ++section) {
- if (section->needsCellRecalc())
</del><ins>+ for (auto& section : childrenOfType<RenderTableSection>(*this)) {
+ if (section.needsCellRecalc())
</ins><span class="cx"> continue;
</span><span class="cx">
</span><del>- section->splitColumn(position, firstSpan);
</del><ins>+ section.splitColumn(position, firstSpan);
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> m_columnPos.grow(numEffCols() + 1);
</span><span class="lines">@@ -826,12 +821,11 @@
</span><span class="cx">
</span><span class="cx"> // Propagate the change in our columns representation to the sections that don't need
</span><span class="cx"> // cell recalc. If they do, they will be synced up directly with m_columns later.
</span><del>- auto sections = childrenOfType<RenderTableSection>(*this);
- for (auto section = sections.begin(), end = sections.end(); section != end; ++section) {
- if (section->needsCellRecalc())
</del><ins>+ for (auto& section : childrenOfType<RenderTableSection>(*this)) {
+ if (section.needsCellRecalc())
</ins><span class="cx"> continue;
</span><span class="cx">
</span><del>- section->appendColumn(newColumnIndex);
</del><ins>+ section.appendColumn(newColumnIndex);
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> m_columnPos.grow(numEffCols() + 1);
</span><span class="lines">@@ -944,9 +938,8 @@
</span><span class="cx">
</span><span class="cx"> // repair column count (addChild can grow it too much, because it always adds elements to the last row of a section)
</span><span class="cx"> unsigned maxCols = 0;
</span><del>- auto sections = childrenOfType<RenderTableSection>(*this);
- for (auto section = sections.begin(), end = sections.end(); section != end; ++section) {
- unsigned sectionCols = section->numColumns();
</del><ins>+ for (auto& section : childrenOfType<RenderTableSection>(*this)) {
+ unsigned sectionCols = section.numColumns();
</ins><span class="cx"> if (sectionCols > maxCols)
</span><span class="cx"> maxCols = sectionCols;
</span><span class="cx"> }
</span></span></pre></div>
<a id="trunkSourceWebCorerenderingRenderTextFragmentcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/rendering/RenderTextFragment.cpp (160597 => 160598)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/rendering/RenderTextFragment.cpp        2013-12-14 17:53:05 UTC (rev 160597)
+++ trunk/Source/WebCore/rendering/RenderTextFragment.cpp        2013-12-14 18:05:45 UTC (rev 160598)
</span><span class="lines">@@ -112,10 +112,9 @@
</span><span class="cx"> {
</span><span class="cx"> if (!m_firstLetter)
</span><span class="cx"> return nullptr;
</span><del>- auto ancestorBlocks = ancestorsOfType<RenderBlock>(*m_firstLetter);
- for (auto block = ancestorBlocks.begin(), end = ancestorBlocks.end(); block != end; ++block) {
- if (block->style().hasPseudoStyle(FIRST_LETTER) && block->canHaveChildren())
- return &*block;
</del><ins>+ for (auto& block : ancestorsOfType<RenderBlock>(*m_firstLetter)) {
+ if (block.style().hasPseudoStyle(FIRST_LETTER) && block.canHaveChildren())
+ return &block;
</ins><span class="cx"> }
</span><span class="cx"> return nullptr;
</span><span class="cx"> }
</span></span></pre></div>
<a id="trunkSourceWebCorerenderingRenderTreeAsTextcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/rendering/RenderTreeAsText.cpp (160597 => 160598)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/rendering/RenderTreeAsText.cpp        2013-12-14 17:53:05 UTC (rev 160597)
+++ trunk/Source/WebCore/rendering/RenderTreeAsText.cpp        2013-12-14 18:05:45 UTC (rev 160598)
</span><span class="lines">@@ -917,12 +917,11 @@
</span><span class="cx"> {
</span><span class="cx"> if (!parent)
</span><span class="cx"> return;
</span><del>- auto counters = childrenOfType<RenderCounter>(*parent);
- for (auto counter = counters.begin(), end = counters.end(); counter != end; ++counter) {
</del><ins>+ for (auto& counter : childrenOfType<RenderCounter>(*parent)) {
</ins><span class="cx"> if (!isFirstCounter)
</span><span class="cx"> stream << " ";
</span><span class="cx"> isFirstCounter = false;
</span><del>- String str(counter->text());
</del><ins>+ String str(counter.text());
</ins><span class="cx"> stream << str;
</span><span class="cx"> }
</span><span class="cx"> }
</span></span></pre></div>
<a id="trunkSourceWebCorerenderingRenderViewcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/rendering/RenderView.cpp (160597 => 160598)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/rendering/RenderView.cpp        2013-12-14 17:53:05 UTC (rev 160597)
+++ trunk/Source/WebCore/rendering/RenderView.cpp        2013-12-14 18:05:45 UTC (rev 160598)
</span><span class="lines">@@ -310,9 +310,7 @@
</span><span class="cx"> if (relayoutChildren) {
</span><span class="cx"> setChildNeedsLayout(MarkOnlyThis);
</span><span class="cx">
</span><del>- auto boxChildren = childrenOfType<RenderBox>(*this);
- for (auto child = boxChildren.begin(), end = boxChildren.end(); child != end; ++child) {
- RenderBox& box = *child;
</del><ins>+ for (auto& box : childrenOfType<RenderBox>(*this)) {
</ins><span class="cx"> if (box.hasRelativeLogicalHeight()
</span><span class="cx"> || box.hasViewportPercentageLogicalHeight()
</span><span class="cx"> || box.style().logicalHeight().isPercent()
</span></span></pre></div>
<a id="trunkSourceWebCorerenderingmathmlRenderMathMLRootcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/rendering/mathml/RenderMathMLRoot.cpp (160597 => 160598)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/rendering/mathml/RenderMathMLRoot.cpp        2013-12-14 17:53:05 UTC (rev 160597)
+++ trunk/Source/WebCore/rendering/mathml/RenderMathMLRoot.cpp        2013-12-14 18:05:45 UTC (rev 160598)
</span><span class="lines">@@ -184,9 +184,8 @@
</span><span class="cx">
</span><span class="cx"> void RenderMathMLRoot::layout()
</span><span class="cx"> {
</span><del>- auto boxChildren = childrenOfType<RenderBox>(*this);
- for (auto box = boxChildren.begin(), end = boxChildren.end(); box != end; ++box)
- box->layoutIfNeeded();
</del><ins>+ for (auto& box : childrenOfType<RenderBox>(*this))
+ box.layoutIfNeeded();
</ins><span class="cx">
</span><span class="cx"> int baseHeight = firstChild() && firstChild()->isBox() ? roundToInt(toRenderBox(firstChild())->logicalHeight()) : style().fontSize();
</span><span class="cx"> int frontWidth = lroundf(gFrontWidthEms * style().fontSize());
</span></span></pre></div>
<a id="trunkSourceWebCorerenderingmathmlRenderMathMLRowcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/rendering/mathml/RenderMathMLRow.cpp (160597 => 160598)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/rendering/mathml/RenderMathMLRow.cpp        2013-12-14 17:53:05 UTC (rev 160597)
+++ trunk/Source/WebCore/rendering/mathml/RenderMathMLRow.cpp        2013-12-14 18:05:45 UTC (rev 160598)
</span><span class="lines">@@ -71,9 +71,8 @@
</span><span class="cx"> stretchLogicalHeight = style().fontSize();
</span><span class="cx">
</span><span class="cx"> // Set the sizes of (possibly embellished) stretchy operator children.
</span><del>- auto children = childrenOfType<RenderMathMLBlock>(*this);
- for (auto child = children.begin(), end = children.end(); child != end; ++child) {
- if (auto renderMo = child->unembellishedOperator()) {
</del><ins>+ for (auto& child : childrenOfType<RenderMathMLBlock>(*this)) {
+ if (auto renderMo = child.unembellishedOperator()) {
</ins><span class="cx"> if (renderMo->stretchHeight() != stretchLogicalHeight)
</span><span class="cx"> renderMo->stretchToHeight(stretchLogicalHeight);
</span><span class="cx"> }
</span></span></pre></div>
<a id="trunkSourceWebCorerenderingsvgRenderSVGContainercpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/rendering/svg/RenderSVGContainer.cpp (160597 => 160598)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/rendering/svg/RenderSVGContainer.cpp        2013-12-14 17:53:05 UTC (rev 160597)
+++ trunk/Source/WebCore/rendering/svg/RenderSVGContainer.cpp        2013-12-14 18:05:45 UTC (rev 160598)
</span><span class="lines">@@ -140,9 +140,8 @@
</span><span class="cx">
</span><span class="cx"> if (continueRendering) {
</span><span class="cx"> childPaintInfo.updateSubtreePaintRootForChildren(this);
</span><del>- auto children = childrenOfType<RenderElement>(*this);
- for (auto child = children.begin(), end = children.end(); child != end; ++child)
- child->paint(childPaintInfo, IntPoint());
</del><ins>+ for (auto& child : childrenOfType<RenderElement>(*this))
+ child.paint(childPaintInfo, IntPoint());
</ins><span class="cx"> }
</span><span class="cx"> }
</span><span class="cx">
</span></span></pre></div>
<a id="trunkSourceWebCorerenderingsvgRenderSVGResourceClippercpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/rendering/svg/RenderSVGResourceClipper.cpp (160597 => 160598)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/rendering/svg/RenderSVGResourceClipper.cpp        2013-12-14 17:53:05 UTC (rev 160597)
+++ trunk/Source/WebCore/rendering/svg/RenderSVGResourceClipper.cpp        2013-12-14 18:05:45 UTC (rev 160598)
</span><span class="lines">@@ -220,9 +220,7 @@
</span><span class="cx"> view().frameView().setPaintBehavior(oldBehavior | PaintBehaviorRenderingSVGMask);
</span><span class="cx">
</span><span class="cx"> // Draw all clipPath children into a global mask.
</span><del>- auto children = childrenOfType<SVGElement>(clipPathElement());
- for (auto it = children.begin(), end = children.end(); it != end; ++it) {
- SVGElement& child = *it;
</del><ins>+ for (auto& child : childrenOfType<SVGElement>(clipPathElement())) {
</ins><span class="cx"> auto renderer = child.renderer();
</span><span class="cx"> if (!renderer)
</span><span class="cx"> continue;
</span></span></pre></div>
<a id="trunkSourceWebCorerenderingsvgRenderSVGResourceFiltercpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/rendering/svg/RenderSVGResourceFilter.cpp (160597 => 160598)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/rendering/svg/RenderSVGResourceFilter.cpp        2013-12-14 17:53:05 UTC (rev 160597)
+++ trunk/Source/WebCore/rendering/svg/RenderSVGResourceFilter.cpp        2013-12-14 18:05:45 UTC (rev 160598)
</span><span class="lines">@@ -93,18 +93,17 @@
</span><span class="cx">
</span><span class="cx"> // Add effects to the builder
</span><span class="cx"> auto builder = std::make_unique<SVGFilterBuilder>(SourceGraphic::create(filter), SourceAlpha::create(filter));
</span><del>- auto children = childrenOfType<SVGFilterPrimitiveStandardAttributes>(filterElement());
- for (auto element = children.begin(), end = children.end(); element != end; ++element) {
- RefPtr<FilterEffect> effect = element->build(builder.get(), filter);
</del><ins>+ for (auto& element : childrenOfType<SVGFilterPrimitiveStandardAttributes>(filterElement())) {
+ RefPtr<FilterEffect> effect = element.build(builder.get(), filter);
</ins><span class="cx"> if (!effect) {
</span><span class="cx"> builder->clearEffects();
</span><span class="cx"> return nullptr;
</span><span class="cx"> }
</span><del>- builder->appendEffectToEffectReferences(effect, element->renderer());
- element->setStandardAttributes(effect.get());
- effect->setEffectBoundaries(SVGLengthContext::resolveRectangle<SVGFilterPrimitiveStandardAttributes>(&*element, filterElement().primitiveUnits(), targetBoundingBox));
- effect->setOperatingColorSpace(element->renderer()->style().svgStyle().colorInterpolationFilters() == CI_LINEARRGB ? ColorSpaceLinearRGB : ColorSpaceDeviceRGB);
- builder->add(element->result(), effect.release());
</del><ins>+ builder->appendEffectToEffectReferences(effect, element.renderer());
+ element.setStandardAttributes(effect.get());
+ effect->setEffectBoundaries(SVGLengthContext::resolveRectangle<SVGFilterPrimitiveStandardAttributes>(&element, filterElement().primitiveUnits(), targetBoundingBox));
+ effect->setOperatingColorSpace(element.renderer()->style().svgStyle().colorInterpolationFilters() == CI_LINEARRGB ? ColorSpaceLinearRGB : ColorSpaceDeviceRGB);
+ builder->add(element.result(), effect.release());
</ins><span class="cx"> }
</span><span class="cx"> return builder;
</span><span class="cx"> }
</span></span></pre></div>
<a id="trunkSourceWebCorerenderingsvgRenderSVGResourceMaskercpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/rendering/svg/RenderSVGResourceMasker.cpp (160597 => 160598)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/rendering/svg/RenderSVGResourceMasker.cpp        2013-12-14 17:53:05 UTC (rev 160597)
+++ trunk/Source/WebCore/rendering/svg/RenderSVGResourceMasker.cpp        2013-12-14 18:05:45 UTC (rev 160598)
</span><span class="lines">@@ -116,9 +116,7 @@
</span><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> // Draw the content into the ImageBuffer.
</span><del>- auto children = childrenOfType<SVGElement>(maskElement());
- for (auto it = children.begin(), end = children.end(); it != end; ++it) {
- SVGElement& child = *it;
</del><ins>+ for (auto& child : childrenOfType<SVGElement>(maskElement())) {
</ins><span class="cx"> auto renderer = child.renderer();
</span><span class="cx"> if (!renderer)
</span><span class="cx"> continue;
</span></span></pre></div>
<a id="trunkSourceWebCorerenderingsvgRenderSVGResourcePatterncpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/rendering/svg/RenderSVGResourcePattern.cpp (160597 => 160598)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/rendering/svg/RenderSVGResourcePattern.cpp        2013-12-14 17:53:05 UTC (rev 160597)
+++ trunk/Source/WebCore/rendering/svg/RenderSVGResourcePattern.cpp        2013-12-14 18:05:45 UTC (rev 160598)
</span><span class="lines">@@ -265,9 +265,7 @@
</span><span class="cx"> contentTransformation = tileImageTransform;
</span><span class="cx">
</span><span class="cx"> // Draw the content into the ImageBuffer.
</span><del>- auto children = childrenOfType<SVGElement>(*attributes.patternContentElement());
- for (auto it = children.begin(), end = children.end(); it != end; ++it) {
- const SVGElement& child = *it;
</del><ins>+ for (auto& child : childrenOfType<SVGElement>(*attributes.patternContentElement())) {
</ins><span class="cx"> if (!child.renderer())
</span><span class="cx"> continue;
</span><span class="cx"> if (child.renderer()->needsLayout())
</span></span></pre></div>
<a id="trunkSourceWebCorerenderingsvgRenderSVGRootcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/rendering/svg/RenderSVGRoot.cpp (160597 => 160598)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/rendering/svg/RenderSVGRoot.cpp        2013-12-14 17:53:05 UTC (rev 160597)
+++ trunk/Source/WebCore/rendering/svg/RenderSVGRoot.cpp        2013-12-14 18:05:45 UTC (rev 160598)
</span><span class="lines">@@ -292,9 +292,8 @@
</span><span class="cx">
</span><span class="cx"> if (continueRendering) {
</span><span class="cx"> childPaintInfo.updateSubtreePaintRootForChildren(this);
</span><del>- auto children = childrenOfType<RenderElement>(*this);
- for (auto child = children.begin(), end = children.end(); child != end; ++child)
- child->paint(childPaintInfo, location());
</del><ins>+ for (auto& child : childrenOfType<RenderElement>(*this))
+ child.paint(childPaintInfo, location());
</ins><span class="cx"> }
</span><span class="cx"> }
</span><span class="cx">
</span></span></pre></div>
<a id="trunkSourceWebCorerenderingsvgSVGResourcesCycleSolvercpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/rendering/svg/SVGResourcesCycleSolver.cpp (160597 => 160598)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/rendering/svg/SVGResourcesCycleSolver.cpp        2013-12-14 17:53:05 UTC (rev 160597)
+++ trunk/Source/WebCore/rendering/svg/SVGResourcesCycleSolver.cpp        2013-12-14 18:05:45 UTC (rev 160598)
</span><span class="lines">@@ -67,24 +67,23 @@
</span><span class="cx"> // Then operate on the child resources of the given renderer.
</span><span class="cx"> // <marker id="a"> <path marker-start="url(#b)"/> ...
</span><span class="cx"> // <marker id="b"> <path marker-start="url(#a)"/> ...
</span><del>- auto children = childrenOfType<RenderElement>(renderer);
- for (auto child = children.begin(), end = children.end(); child != end; ++child) {
- SVGResources* childResources = SVGResourcesCache::cachedResourcesForRenderObject(&*child);
</del><ins>+ for (auto& child : childrenOfType<RenderElement>(renderer)) {
+ SVGResources* childResources = SVGResourcesCache::cachedResourcesForRenderObject(&child);
</ins><span class="cx"> if (!childResources)
</span><span class="cx"> continue;
</span><span class="cx">
</span><span class="cx"> // A child of the given 'resource' contains resources.
</span><del>- HashSet<RenderSVGResourceContainer*> childSet;
- childResources->buildSetOfResources(childSet);
</del><ins>+ HashSet<RenderSVGResourceContainer*> childResourceSet;
+ childResources->buildSetOfResources(childResourceSet);
</ins><span class="cx">
</span><span class="cx"> // Walk all child resources and check wheter they reference any resource contained in the resources set.
</span><del>- for (auto it = childSet.begin(), end = childSet.end(); it != end; ++it) {
- if (m_allResources.contains(*it))
</del><ins>+ for (auto& resource : childResourceSet) {
+ if (m_allResources.contains(resource))
</ins><span class="cx"> return true;
</span><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> // Walk children recursively, stop immediately if we found a cycle
</span><del>- if (resourceContainsCycles(*child))
</del><ins>+ if (resourceContainsCycles(child))
</ins><span class="cx"> return true;
</span><span class="cx"> }
</span><span class="cx">
</span></span></pre></div>
<a id="trunkSourceWebCoresvgSVGAltGlyphDefElementcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/svg/SVGAltGlyphDefElement.cpp (160597 => 160598)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/svg/SVGAltGlyphDefElement.cpp        2013-12-14 17:53:05 UTC (rev 160597)
+++ trunk/Source/WebCore/svg/SVGAltGlyphDefElement.cpp        2013-12-14 18:05:45 UTC (rev 160598)
</span><span class="lines">@@ -89,9 +89,7 @@
</span><span class="cx"> bool fountFirstGlyphRef = false;
</span><span class="cx"> bool foundFirstAltGlyphItem = false;
</span><span class="cx">
</span><del>- auto svgChildren = childrenOfType<SVGElement>(*this);
- for (auto it = svgChildren.begin(), end = svgChildren.end(); it != end; ++it) {
- const SVGElement& child = *it;
</del><ins>+ for (auto& child : childrenOfType<SVGElement>(*this)) {
</ins><span class="cx"> if (!foundFirstAltGlyphItem && isSVGGlyphRefElement(child)) {
</span><span class="cx"> fountFirstGlyphRef = true;
</span><span class="cx"> String referredGlyphName;
</span></span></pre></div>
<a id="trunkSourceWebCoresvgSVGAltGlyphItemElementcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/svg/SVGAltGlyphItemElement.cpp (160597 => 160598)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/svg/SVGAltGlyphItemElement.cpp        2013-12-14 17:53:05 UTC (rev 160597)
+++ trunk/Source/WebCore/svg/SVGAltGlyphItemElement.cpp        2013-12-14 18:05:45 UTC (rev 160598)
</span><span class="lines">@@ -50,10 +50,9 @@
</span><span class="cx"> // Here we fill glyphNames and return true only if all referenced glyphs are valid and
</span><span class="cx"> // there is at least one glyph.
</span><span class="cx">
</span><del>- auto glyphChildren = childrenOfType<SVGGlyphRefElement>(*this);
- for (auto glyphRef = glyphChildren.begin(), end = glyphChildren.end(); glyphRef != end; ++glyphRef) {
</del><ins>+ for (auto& glyphRef : childrenOfType<SVGGlyphRefElement>(*this)) {
</ins><span class="cx"> String referredGlyphName;
</span><del>- if (glyphRef->hasValidGlyphElement(referredGlyphName))
</del><ins>+ if (glyphRef.hasValidGlyphElement(referredGlyphName))
</ins><span class="cx"> glyphNames.append(referredGlyphName);
</span><span class="cx"> else {
</span><span class="cx"> glyphNames.clear();
</span></span></pre></div>
<a id="trunkSourceWebCoresvgSVGAnimateMotionElementcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/svg/SVGAnimateMotionElement.cpp (160597 => 160598)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/svg/SVGAnimateMotionElement.cpp        2013-12-14 17:53:05 UTC (rev 160597)
+++ trunk/Source/WebCore/svg/SVGAnimateMotionElement.cpp        2013-12-14 18:05:45 UTC (rev 160598)
</span><span class="lines">@@ -139,9 +139,8 @@
</span><span class="cx"> m_animationPath = Path();
</span><span class="cx"> bool foundMPath = false;
</span><span class="cx">
</span><del>- auto mPathChildren = childrenOfType<SVGMPathElement>(*this);
- for (auto mPath = mPathChildren.begin(), end = mPathChildren.end(); mPath != end; ++mPath) {
- SVGPathElement* pathElement = mPath->pathElement();
</del><ins>+ for (auto& mPath : childrenOfType<SVGMPathElement>(*this)) {
+ SVGPathElement* pathElement = mPath.pathElement();
</ins><span class="cx"> if (pathElement) {
</span><span class="cx"> updatePathFromGraphicsElement(pathElement, m_animationPath);
</span><span class="cx"> foundMPath = true;
</span></span></pre></div>
<a id="trunkSourceWebCoresvgSVGElementcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/svg/SVGElement.cpp (160597 => 160598)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/svg/SVGElement.cpp        2013-12-14 17:53:05 UTC (rev 160597)
+++ trunk/Source/WebCore/svg/SVGElement.cpp        2013-12-14 18:05:45 UTC (rev 160598)
</span><span class="lines">@@ -510,9 +510,8 @@
</span><span class="cx">
</span><span class="cx"> bool SVGElement::haveLoadedRequiredResources()
</span><span class="cx"> {
</span><del>- auto svgChildren = childrenOfType<SVGElement>(*this);
- for (auto child = svgChildren.begin(), end = svgChildren.end(); child != end; ++child) {
- if (!child->haveLoadedRequiredResources())
</del><ins>+ for (auto& child : childrenOfType<SVGElement>(*this)) {
+ if (!child.haveLoadedRequiredResources())
</ins><span class="cx"> return false;
</span><span class="cx"> }
</span><span class="cx"> return true;
</span></span></pre></div>
<a id="trunkSourceWebCoresvgSVGFEComponentTransferElementcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/svg/SVGFEComponentTransferElement.cpp (160597 => 160598)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/svg/SVGFEComponentTransferElement.cpp        2013-12-14 17:53:05 UTC (rev 160597)
+++ trunk/Source/WebCore/svg/SVGFEComponentTransferElement.cpp        2013-12-14 18:05:45 UTC (rev 160598)
</span><span class="lines">@@ -83,24 +83,22 @@
</span><span class="cx"> FilterEffect* input1 = filterBuilder->getEffectById(in1());
</span><span class="cx">
</span><span class="cx"> if (!input1)
</span><del>- return 0;
</del><ins>+ return nullptr;
</ins><span class="cx">
</span><span class="cx"> ComponentTransferFunction red;
</span><span class="cx"> ComponentTransferFunction green;
</span><span class="cx"> ComponentTransferFunction blue;
</span><span class="cx"> ComponentTransferFunction alpha;
</span><span class="cx">
</span><del>- auto children = childrenOfType<SVGElement>(*this);
- for (auto child = children.begin(), end = children.end(); child != end; ++child) {
- SVGElement* element = &*child;
- if (isSVGFEFuncRElement(element))
- red = toSVGFEFuncRElement(element)->transferFunction();
- else if (isSVGFEFuncGElement(element))
- green = toSVGFEFuncGElement(element)->transferFunction();
- else if (isSVGFEFuncBElement(element))
- blue = toSVGFEFuncBElement(element)->transferFunction();
- else if (isSVGFEFuncAElement(element))
- alpha = toSVGFEFuncAElement(element)->transferFunction();
</del><ins>+ for (auto& child : childrenOfType<SVGElement>(*this)) {
+ if (isSVGFEFuncRElement(child))
+ red = toSVGFEFuncRElement(child).transferFunction();
+ else if (isSVGFEFuncGElement(child))
+ green = toSVGFEFuncGElement(child).transferFunction();
+ else if (isSVGFEFuncBElement(child))
+ blue = toSVGFEFuncBElement(child).transferFunction();
+ else if (isSVGFEFuncAElement(child))
+ alpha = toSVGFEFuncAElement(child).transferFunction();
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> RefPtr<FilterEffect> effect = FEComponentTransfer::create(filter, red, green, blue, alpha);
</span></span></pre></div>
<a id="trunkSourceWebCoresvgSVGFELightElementcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/svg/SVGFELightElement.cpp (160597 => 160598)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/svg/SVGFELightElement.cpp        2013-12-14 17:53:05 UTC (rev 160597)
+++ trunk/Source/WebCore/svg/SVGFELightElement.cpp        2013-12-14 18:05:45 UTC (rev 160598)
</span><span class="lines">@@ -71,12 +71,11 @@
</span><span class="cx">
</span><span class="cx"> SVGFELightElement* SVGFELightElement::findLightElement(const SVGElement* svgElement)
</span><span class="cx"> {
</span><del>- auto children = childrenOfType<SVGElement>(*svgElement);
- for (auto child = children.begin(), end = children.end(); child != end; ++child) {
- if (isSVGFEDistantLightElement(*child) || isSVGFEPointLightElement(*child) || isSVGFESpotLightElement(*child))
- return static_cast<SVGFELightElement*>(const_cast<SVGElement*>(&*child));
</del><ins>+ for (auto& child : childrenOfType<SVGElement>(*svgElement)) {
+ if (isSVGFEDistantLightElement(child) || isSVGFEPointLightElement(child) || isSVGFESpotLightElement(child))
+ return static_cast<SVGFELightElement*>(const_cast<SVGElement*>(&child));
</ins><span class="cx"> }
</span><del>- return 0;
</del><ins>+ return nullptr;
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> PassRefPtr<LightSource> SVGFELightElement::findLightSource(const SVGElement* svgElement)
</span></span></pre></div>
<a id="trunkSourceWebCoresvgSVGFEMergeElementcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/svg/SVGFEMergeElement.cpp (160597 => 160598)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/svg/SVGFEMergeElement.cpp        2013-12-14 17:53:05 UTC (rev 160597)
+++ trunk/Source/WebCore/svg/SVGFEMergeElement.cpp        2013-12-14 18:05:45 UTC (rev 160598)
</span><span class="lines">@@ -47,16 +47,15 @@
</span><span class="cx"> RefPtr<FilterEffect> effect = FEMerge::create(filter);
</span><span class="cx"> FilterEffectVector& mergeInputs = effect->inputEffects();
</span><span class="cx">
</span><del>- auto children = childrenOfType<SVGFEMergeNodeElement>(*this);
- for (auto mergeNode = children.begin(), end = children.end(); mergeNode != end; ++mergeNode) {
- FilterEffect* mergeEffect = filterBuilder->getEffectById(mergeNode->in1());
</del><ins>+ for (auto& mergeNode : childrenOfType<SVGFEMergeNodeElement>(*this)) {
+ FilterEffect* mergeEffect = filterBuilder->getEffectById(mergeNode.in1());
</ins><span class="cx"> if (!mergeEffect)
</span><del>- return 0;
</del><ins>+ return nullptr;
</ins><span class="cx"> mergeInputs.append(mergeEffect);
</span><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> if (mergeInputs.isEmpty())
</span><del>- return 0;
</del><ins>+ return nullptr;
</ins><span class="cx">
</span><span class="cx"> return effect.release();
</span><span class="cx"> }
</span></span></pre></div>
<a id="trunkSourceWebCoresvgSVGFontElementcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/svg/SVGFontElement.cpp (160597 => 160598)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/svg/SVGFontElement.cpp        2013-12-14 17:53:05 UTC (rev 160597)
+++ trunk/Source/WebCore/svg/SVGFontElement.cpp        2013-12-14 18:05:45 UTC (rev 160598)
</span><span class="lines">@@ -118,29 +118,27 @@
</span><span class="cx">
</span><span class="cx"> const SVGMissingGlyphElement* firstMissingGlyphElement = nullptr;
</span><span class="cx"> Vector<String> ligatures;
</span><del>- auto children = childrenOfType<SVGElement>(*this);
- for (auto child = children.begin(), end = children.end(); child != end; ++child) {
- SVGElement* element = &*child;
- if (isSVGGlyphElement(element)) {
- SVGGlyphElement* glyph = toSVGGlyphElement(element);
- AtomicString unicode = glyph->fastGetAttribute(SVGNames::unicodeAttr);
- AtomicString glyphId = glyph->getIdAttribute();
</del><ins>+ for (auto& child : childrenOfType<SVGElement>(*this)) {
+ if (isSVGGlyphElement(child)) {
+ SVGGlyphElement& glyph = toSVGGlyphElement(child);
+ AtomicString unicode = glyph.fastGetAttribute(SVGNames::unicodeAttr);
+ AtomicString glyphId = glyph.getIdAttribute();
</ins><span class="cx"> if (glyphId.isEmpty() && unicode.isEmpty())
</span><span class="cx"> continue;
</span><span class="cx">
</span><del>- m_glyphMap.addGlyph(glyphId, unicode, glyph->buildGlyphIdentifier());
</del><ins>+ m_glyphMap.addGlyph(glyphId, unicode, glyph.buildGlyphIdentifier());
</ins><span class="cx">
</span><span class="cx"> // Register ligatures, if needed, don't mix up with surrogate pairs though!
</span><span class="cx"> if (unicode.length() > 1 && !U16_IS_SURROGATE(unicode[0]))
</span><span class="cx"> ligatures.append(unicode.string());
</span><del>- } else if (isSVGHKernElement(element)) {
- SVGHKernElement* hkern = toSVGHKernElement(element);
- hkern->buildHorizontalKerningPair(m_horizontalKerningMap);
- } else if (isSVGVKernElement(element)) {
- SVGVKernElement* vkern = toSVGVKernElement(element);
- vkern->buildVerticalKerningPair(m_verticalKerningMap);
- } else if (isSVGMissingGlyphElement(element) && !firstMissingGlyphElement)
- firstMissingGlyphElement = toSVGMissingGlyphElement(element);
</del><ins>+ } else if (isSVGHKernElement(child)) {
+ SVGHKernElement& hkern = toSVGHKernElement(child);
+ hkern.buildHorizontalKerningPair(m_horizontalKerningMap);
+ } else if (isSVGVKernElement(child)) {
+ SVGVKernElement& vkern = toSVGVKernElement(child);
+ vkern.buildVerticalKerningPair(m_verticalKerningMap);
+ } else if (isSVGMissingGlyphElement(child) && !firstMissingGlyphElement)
+ firstMissingGlyphElement = &toSVGMissingGlyphElement(child);
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> // Register each character of each ligature, if needed.
</span></span></pre></div>
<a id="trunkSourceWebCoresvgSVGFontFaceSrcElementcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/svg/SVGFontFaceSrcElement.cpp (160597 => 160598)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/svg/SVGFontFaceSrcElement.cpp        2013-12-14 17:53:05 UTC (rev 160597)
+++ trunk/Source/WebCore/svg/SVGFontFaceSrcElement.cpp        2013-12-14 18:05:45 UTC (rev 160598)
</span><span class="lines">@@ -48,13 +48,12 @@
</span><span class="cx"> PassRefPtr<CSSValueList> SVGFontFaceSrcElement::srcValue() const
</span><span class="cx"> {
</span><span class="cx"> RefPtr<CSSValueList> list = CSSValueList::createCommaSeparated();
</span><del>- auto svgChildren = childrenOfType<SVGElement>(*this);
- for (auto child = svgChildren.begin(), end = svgChildren.end(); child != end; ++child) {
</del><ins>+ for (auto& child : childrenOfType<SVGElement>(*this)) {
</ins><span class="cx"> RefPtr<CSSFontFaceSrcValue> srcValue;
</span><del>- if (isSVGFontFaceUriElement(*child))
- srcValue = toSVGFontFaceUriElement(*child).srcValue();
- else if (isSVGFontFaceNameElement(*child))
- srcValue = toSVGFontFaceNameElement(*child).srcValue();
</del><ins>+ if (isSVGFontFaceUriElement(child))
+ srcValue = toSVGFontFaceUriElement(child).srcValue();
+ else if (isSVGFontFaceNameElement(child))
+ srcValue = toSVGFontFaceNameElement(child).srcValue();
</ins><span class="cx"> if (srcValue && srcValue->resource().length())
</span><span class="cx"> list->append(srcValue.release());
</span><span class="cx"> }
</span></span></pre></div>
<a id="trunkSourceWebCoresvgSVGGradientElementcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/svg/SVGGradientElement.cpp (160597 => 160598)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/svg/SVGGradientElement.cpp        2013-12-14 17:53:05 UTC (rev 160597)
+++ trunk/Source/WebCore/svg/SVGGradientElement.cpp        2013-12-14 18:05:45 UTC (rev 160598)
</span><span class="lines">@@ -140,15 +140,13 @@
</span><span class="cx"> Vector<Gradient::ColorStop> SVGGradientElement::buildStops()
</span><span class="cx"> {
</span><span class="cx"> Vector<Gradient::ColorStop> stops;
</span><del>-
- auto stopChildren = childrenOfType<SVGStopElement>(*this);
</del><span class="cx"> float previousOffset = 0.0f;
</span><span class="cx">
</span><del>- for (auto stop = stopChildren.begin(), end = stopChildren.end(); stop != end; ++stop) {
- Color color = stop->stopColorIncludingOpacity();
</del><ins>+ for (auto& stop : childrenOfType<SVGStopElement>(*this)) {
+ Color color = stop.stopColorIncludingOpacity();
</ins><span class="cx">
</span><span class="cx"> // Figure out right monotonic offset
</span><del>- float offset = stop->offset();
</del><ins>+ float offset = stop.offset();
</ins><span class="cx"> offset = std::min(std::max(previousOffset, offset), 1.0f);
</span><span class="cx"> previousOffset = offset;
</span><span class="cx">
</span></span></pre></div>
<a id="trunkSourceWebCoresvgSVGSVGElementcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/svg/SVGSVGElement.cpp (160597 => 160598)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/svg/SVGSVGElement.cpp        2013-12-14 17:53:05 UTC (rev 160597)
+++ trunk/Source/WebCore/svg/SVGSVGElement.cpp        2013-12-14 18:05:45 UTC (rev 160598)
</span><span class="lines">@@ -337,15 +337,13 @@
</span><span class="cx"> {
</span><span class="cx"> Vector<Ref<Element>> elements;
</span><span class="cx">
</span><del>- auto svgDescendants = descendantsOfType<SVGElement>(*(referenceElement ? referenceElement : this));
- for (auto it = svgDescendants.begin(), end = svgDescendants.end(); it != end; ++it) {
- const SVGElement* svgElement = &*it;
</del><ins>+ for (auto& svgElement : descendantsOfType<SVGElement>(*(referenceElement ? referenceElement : this))) {
</ins><span class="cx"> if (collect == CollectIntersectionList) {
</span><del>- if (RenderSVGModelObject::checkIntersection(svgElement->renderer(), rect))
- elements.append(*const_cast<SVGElement*>(svgElement));
</del><ins>+ if (RenderSVGModelObject::checkIntersection(svgElement.renderer(), rect))
+ elements.append(const_cast<SVGElement&>(svgElement));
</ins><span class="cx"> } else {
</span><del>- if (RenderSVGModelObject::checkEnclosure(svgElement->renderer(), rect))
- elements.append(*const_cast<SVGElement*>(svgElement));
</del><ins>+ if (RenderSVGModelObject::checkEnclosure(svgElement.renderer(), rect))
+ elements.append(const_cast<SVGElement&>(svgElement));
</ins><span class="cx"> }
</span><span class="cx"> }
</span><span class="cx">
</span><span class="lines">@@ -777,10 +775,9 @@
</span><span class="cx">
</span><span class="cx"> // Fall back to traversing our subtree. Duplicate ids are allowed, the first found will
</span><span class="cx"> // be returned.
</span><del>- auto descendants = elementDescendants(*this);
- for (auto element = descendants.begin(), end = descendants.end(); element != end; ++element) {
- if (element->getIdAttribute() == id)
- return &*element;
</del><ins>+ for (auto& element : elementDescendants(*this)) {
+ if (element.getIdAttribute() == id)
+ return &element;
</ins><span class="cx"> }
</span><span class="cx"> return 0;
</span><span class="cx"> }
</span></span></pre></div>
<a id="trunkSourceWebCoresvgSVGSwitchElementcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/svg/SVGSwitchElement.cpp (160597 => 160598)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/svg/SVGSwitchElement.cpp        2013-12-14 17:53:05 UTC (rev 160597)
+++ trunk/Source/WebCore/svg/SVGSwitchElement.cpp        2013-12-14 18:05:45 UTC (rev 160598)
</span><span class="lines">@@ -53,11 +53,10 @@
</span><span class="cx"> {
</span><span class="cx"> // FIXME: This function does not do what the comment below implies it does.
</span><span class="cx"> // It will create a renderer for any valid SVG element children, not just the first one.
</span><del>- auto svgChildren = childrenOfType<SVGElement>(*this);
- for (auto element = svgChildren.begin(), end = svgChildren.end(); element != end; ++element) {
- if (!element->isValid())
</del><ins>+ for (auto& element : childrenOfType<SVGElement>(*this)) {
+ if (!element.isValid())
</ins><span class="cx"> continue;
</span><del>- return &*element == &child; // Only allow this child if it's the first valid child
</del><ins>+ return &element == &child; // Only allow this child if it's the first valid child
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> return false;
</span></span></pre></div>
<a id="trunkSourceWebCoresvgSVGUseElementcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/svg/SVGUseElement.cpp (160597 => 160598)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/svg/SVGUseElement.cpp        2013-12-14 17:53:05 UTC (rev 160597)
+++ trunk/Source/WebCore/svg/SVGUseElement.cpp        2013-12-14 18:05:45 UTC (rev 160598)
</span><span class="lines">@@ -369,9 +369,8 @@
</span><span class="cx">
</span><span class="cx"> static bool subtreeContainsDisallowedElement(SVGElement& start)
</span><span class="cx"> {
</span><del>- auto descendants = elementDescendants(start);
- for (auto element = descendants.begin(), end = descendants.end(); element != end; ++element) {
- if (isDisallowedElement(*element))
</del><ins>+ for (auto& element : elementDescendants(start)) {
+ if (isDisallowedElement(element))
</ins><span class="cx"> return true;
</span><span class="cx"> }
</span><span class="cx">
</span><span class="lines">@@ -606,19 +605,18 @@
</span><span class="cx"> // is the SVGGElement object for the 'g', and then two child SVGElementInstance objects, each of which has
</span><span class="cx"> // its correspondingElement that is an SVGRectElement object.
</span><span class="cx">
</span><del>- auto svgChildren = childrenOfType<SVGElement>(*target);
- for (auto element = svgChildren.begin(), end = svgChildren.end(); element != end; ++element) {
</del><ins>+ for (auto& element : childrenOfType<SVGElement>(*target)) {
</ins><span class="cx"> // Skip any non-svg nodes or any disallowed element.
</span><del>- if (isDisallowedElement(*element))
</del><ins>+ if (isDisallowedElement(element))
</ins><span class="cx"> continue;
</span><span class="cx">
</span><span class="cx"> // Create SVGElementInstance object, for both container/non-container nodes.
</span><del>- RefPtr<SVGElementInstance> instance = SVGElementInstance::create(this, 0, &*element);
</del><ins>+ RefPtr<SVGElementInstance> instance = SVGElementInstance::create(this, 0, &element);
</ins><span class="cx"> SVGElementInstance* instancePtr = instance.get();
</span><span class="cx"> targetInstance->appendChild(instance.release());
</span><span class="cx">
</span><span class="cx"> // Enter recursion, appending new instance tree nodes to the "instance" object.
</span><del>- buildInstanceTree(&*element, instancePtr, foundProblem, foundUse);
</del><ins>+ buildInstanceTree(&element, instancePtr, foundProblem, foundUse);
</ins><span class="cx"> if (foundProblem)
</span><span class="cx"> return;
</span><span class="cx"> }
</span></span></pre></div>
<a id="trunkSourceWebCoresvganimationSMILTimeContainercpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/svg/animation/SMILTimeContainer.cpp (160597 => 160598)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/svg/animation/SMILTimeContainer.cpp        2013-12-14 17:53:05 UTC (rev 160597)
+++ trunk/Source/WebCore/svg/animation/SMILTimeContainer.cpp        2013-12-14 18:05:45 UTC (rev 160598)
</span><span class="lines">@@ -226,9 +226,8 @@
</span><span class="cx"> {
</span><span class="cx"> unsigned timingElementCount = 0;
</span><span class="cx">
</span><del>- auto smilDescendants = descendantsOfType<SVGSMILElement>(*m_ownerSVGElement);
- for (auto smilElement = smilDescendants.begin(), end = smilDescendants.end(); smilElement != end; ++smilElement)
- smilElement->setDocumentOrderIndex(timingElementCount++);
</del><ins>+ for (auto& smilElement : descendantsOfType<SVGSMILElement>(*m_ownerSVGElement))
+ smilElement.setDocumentOrderIndex(timingElementCount++);
</ins><span class="cx">
</span><span class="cx"> m_documentOrderIndexesDirty = false;
</span><span class="cx"> }
</span></span></pre>
</div>
</div>
</body>
</html>