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

Unified Diff: Source/core/dom/ElementRareData.h

Issue 27513004: Make ElementRareData::ensureShadow() return a reference (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Fix nit Created 7 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « Source/core/dom/Element.cpp ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/dom/ElementRareData.h
diff --git a/Source/core/dom/ElementRareData.h b/Source/core/dom/ElementRareData.h
index 956eda783b4e507214e46bbdbead22154cef6b81..06085318dbef48a98e102d1bcd3cdf5fb1df7973 100644
--- a/Source/core/dom/ElementRareData.h
+++ b/Source/core/dom/ElementRareData.h
@@ -98,11 +98,11 @@ public:
void clearShadow() { m_shadow = nullptr; }
ElementShadow* shadow() const { return m_shadow.get(); }
- ElementShadow* ensureShadow()
+ ElementShadow& ensureShadow()
{
if (!m_shadow)
m_shadow = ElementShadow::create();
- return m_shadow.get();
+ return *m_shadow;
}
NamedNodeMap* attributeMap() const { return m_attributeMap.get(); }
« no previous file with comments | « Source/core/dom/Element.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698