diff options
Diffstat (limited to 'layout/style/nsCSSParser.cpp')
-rw-r--r-- | layout/style/nsCSSParser.cpp | 46 |
1 files changed, 27 insertions, 19 deletions
diff --git a/layout/style/nsCSSParser.cpp b/layout/style/nsCSSParser.cpp index b409bfed7e..2ba1e9b7f3 100644 --- a/layout/style/nsCSSParser.cpp +++ b/layout/style/nsCSSParser.cpp @@ -9710,13 +9710,6 @@ CSSParserImpl::ParseGrid() return true; } - // https://drafts.csswg.org/css-grid/#grid-shorthand - // "Also, the gutter properties are reset by this shorthand, - // even though they can't be set by it." - value.SetFloatValue(0.0f, eCSSUnit_Pixel); - AppendValue(eCSSProperty_row_gap, value); - AppendValue(eCSSProperty_column_gap, value); - // [ auto-flow && dense? ] <'grid-auto-rows'>? / <'grid-template-columns'> auto res = ParseGridShorthandAutoProps(NS_STYLE_GRID_AUTO_FLOW_ROW); if (res == CSSParseResult::Error) { @@ -9843,7 +9836,22 @@ CSSParserImpl::ParseGridLine(nsCSSValue& aValue) // Make the contained value be defined even though we really want a // Nothing here. This works around an otherwise difficult to avoid // Memcheck false positive when this is compiled by gcc-5.3 -O2. - // See bug 1301856. + // The problem is that gcc 5.4 and later, when using high + // optimization, inline Maybe::{isSome,ref} here + // + // if (integer.isSome() && integer.ref() < 0) { + // + // and then proceed to evaluate the expression right-to-left, as if it + // had been written + // + // integer.ref() < 0 && integer.isSome() + // + // This is a legitimate transformation because gcc presumably can prove + // via dataflow analysis that integer.isSome() is false whenever integer.ref() + // is undefined, so the overall expression result is still defined. + // Valgrind/Memcheck assumes that all conditional branches in the program + // are important, and that assumption is deeply wired in, so there is no + // easy way to avoid the warning apart from to force-initialise |integer|. integer.emplace(0); integer.reset(); #endif @@ -15314,17 +15322,17 @@ CSSParserImpl::ParseFontFeatureSettings(nsCSSValue& aValue) return true; } -bool
-CSSParserImpl::ParseFontVariationSettings(nsCSSValue& aValue)
-{
- // TODO: Actually implement this.
-
- // This stub is here because websites insist on considering this
- // very hardware-dependent and O.S.-variable low-level font-control
- // as a "critical feature" which it isn't as there is 0 guarantee
- // that font variation settings are supported or honored by any
- // operating system used by the client.
- return true;
+bool +CSSParserImpl::ParseFontVariationSettings(nsCSSValue& aValue) +{ + // TODO: Actually implement this. + + // This stub is here because websites insist on considering this + // very hardware-dependent and O.S.-variable low-level font-control + // as a "critical feature" which it isn't as there is 0 guarantee + // that font variation settings are supported or honored by any + // operating system used by the client. + return true; } bool |