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

Unified Diff: Source/core/css/parser/CSSPropertyParser.cpp

Issue 569563002: [CSSGridLayout] ASSERTION: Bad cast in parseGridTemplateRowsAndAreas (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 6 years, 3 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/css/parser/CSSPropertyParser.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/css/parser/CSSPropertyParser.cpp
diff --git a/Source/core/css/parser/CSSPropertyParser.cpp b/Source/core/css/parser/CSSPropertyParser.cpp
index 46356995453c0de4b91b02e3fcf74b79a671f167..4191e1fd3542e841f0fb7e697084bf4e99efc1f0 100644
--- a/Source/core/css/parser/CSSPropertyParser.cpp
+++ b/Source/core/css/parser/CSSPropertyParser.cpp
@@ -3358,10 +3358,8 @@ bool CSSPropertyParser::parseGridTemplateRowsAndAreas(PassRefPtrWillBeRawPtr<CSS
// This will handle the trailing/leading <custom-ident>* in the grammar.
trailingIdentWasAdded = false;
- if (m_valueList->current() && m_valueList->current()->unit == CSSParserValue::ValueList) {
- parseGridLineNames(*m_valueList, *templateRows);
- trailingIdentWasAdded = true;
- }
+ if (m_valueList->current() && m_valueList->current()->unit == CSSParserValue::ValueList)
Julien - ping for review 2014/09/12 14:51:36 Nit: We could even remove this branch together: t
+ trailingIdentWasAdded = parseGridLineNames(*m_valueList, *templateRows);
}
// [<track-list> /]?
@@ -3549,14 +3547,14 @@ bool CSSPropertyParser::parseSingleGridAreaLonghand(RefPtrWillBeRawPtr<CSSValue>
return true;
}
-void CSSPropertyParser::parseGridLineNames(CSSParserValueList& inputList, CSSValueList& valueList, CSSGridLineNamesValue* previousNamedAreaTrailingLineNames)
+bool CSSPropertyParser::parseGridLineNames(CSSParserValueList& inputList, CSSValueList& valueList, CSSGridLineNamesValue* previousNamedAreaTrailingLineNames)
{
ASSERT(inputList.current() && inputList.current()->unit == CSSParserValue::ValueList);
CSSParserValueList* identList = inputList.current()->valueList;
if (!identList->size()) {
inputList.next();
- return;
+ return false;
}
// Need to ensure the identList is at the heading index, since the parserList might have been rewound.
@@ -3575,6 +3573,7 @@ void CSSPropertyParser::parseGridLineNames(CSSParserValueList& inputList, CSSVal
valueList.append(lineNames.release());
inputList.next();
+ return true;
}
PassRefPtrWillBeRawPtr<CSSValue> CSSPropertyParser::parseGridTrackList()
« no previous file with comments | « Source/core/css/parser/CSSPropertyParser.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698