mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 1203142 - Insert /**/ separate between two adjacent '-' symbols when serializing token streams. r=simon.sapin
This commit is contained in:
parent
f0267b0b03
commit
4feb2989f7
@ -2145,6 +2145,7 @@ SeparatorRequiredBetweenTokens(nsCSSTokenSerializationType aToken1,
|
||||
aToken2 == eCSSTokenSerialization_URange ||
|
||||
aToken2 == eCSSTokenSerialization_CDC;
|
||||
case eCSSTokenSerialization_Symbol_Hash:
|
||||
case eCSSTokenSerialization_Symbol_Minus:
|
||||
return aToken2 == eCSSTokenSerialization_Ident ||
|
||||
aToken2 == eCSSTokenSerialization_Function ||
|
||||
aToken2 == eCSSTokenSerialization_URL_or_BadURL ||
|
||||
@ -2153,7 +2154,6 @@ SeparatorRequiredBetweenTokens(nsCSSTokenSerializationType aToken1,
|
||||
aToken2 == eCSSTokenSerialization_Percentage ||
|
||||
aToken2 == eCSSTokenSerialization_Dimension ||
|
||||
aToken2 == eCSSTokenSerialization_URange;
|
||||
case eCSSTokenSerialization_Symbol_Minus:
|
||||
case eCSSTokenSerialization_Number:
|
||||
return aToken2 == eCSSTokenSerialization_Ident ||
|
||||
aToken2 == eCSSTokenSerialization_Function ||
|
||||
|
@ -104,7 +104,7 @@ enum nsCSSTokenType {
|
||||
// need to insert a "/**/" string between a '|' delim and a '|=' dashmatch
|
||||
// and between a '/' delim and a '*=' containsmatch.
|
||||
//
|
||||
// https://dvcs.w3.org/hg/csswg/raw-file/372e659027a0/css-syntax/Overview.html#serialization
|
||||
// https://drafts.csswg.org/css-syntax/#serialization
|
||||
enum nsCSSTokenSerializationType {
|
||||
eCSSTokenSerialization_Nothing,
|
||||
eCSSTokenSerialization_Whitespace,
|
||||
|
@ -35,6 +35,12 @@ var values = [
|
||||
["--a: var(--b)var(--c); --b:orange; --c:red;", "--a", " orange/**/red"],
|
||||
["--a: var(--b)var(--c,red); --b:orange;", "--a", " orange/**/red"],
|
||||
["--a: var(--b,orange)var(--c); --c:red;", "--a", " orange/**/red"],
|
||||
["--a: var(--b)-; --b:-;", "--a", " -/**/-"],
|
||||
["--a: var(--b)--; --b:-;", "--a", " -/**/--"],
|
||||
["--a: var(--b)--x; --b:-;", "--a", " -/**/--x"],
|
||||
["--a: var(--b)var(--c); --b:-; --c:-;", "--a", " -/**/-"],
|
||||
["--a: var(--b)var(--c); --b:--; --c:-;", "--a", " --/**/-"],
|
||||
["--a: var(--b)var(--c); --b:--x; --c:-;", "--a", " --x/**/-"],
|
||||
["counter-reset: var(--a)red; --a:orange;", "counter-reset", "orange 0 red 0"],
|
||||
["--a: var(--b)var(--c); --c:[c]; --b:('ab", "--a", " ('ab')[c]"],
|
||||
["--a: '", "--a", " ''"],
|
||||
|
Loading…
Reference in New Issue
Block a user