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

Unified Diff: Source/core/svg/SVGPathSegList.cpp

Issue 19914002: Use toSVGPathElement() instead of static_cast<> (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 7 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: Source/core/svg/SVGPathSegList.cpp
diff --git a/Source/core/svg/SVGPathSegList.cpp b/Source/core/svg/SVGPathSegList.cpp
index e10e1fa9236691e1655b2916c7387aa4a0b7173a..475a0437d95d23422324054fd6040f180adcf078 100644
--- a/Source/core/svg/SVGPathSegList.cpp
+++ b/Source/core/svg/SVGPathSegList.cpp
@@ -40,8 +40,7 @@ String SVGPathSegList::valueAsString() const
void SVGPathSegList::commitChange(SVGElement* contextElement, ListModification listModification)
{
ASSERT(contextElement);
- ASSERT(contextElement->hasTagName(SVGNames::pathTag));
- static_cast<SVGPathElement*>(contextElement)->pathSegListChanged(m_role, listModification);
+ toSVGPathElement(contextElement)->pathSegListChanged(m_role, listModification);
}
}
« no previous file with comments | « Source/core/svg/SVGPathElement.h ('k') | Source/core/svg/properties/SVGAnimatedPathSegListPropertyTearOff.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698