SeparatorRequiredBetweenTokens() needs to return true for two dashes

RESOLVED FIXED in Firefox 43

Status

()

defect
RESOLVED FIXED
4 years ago
4 years ago

People

(Reporter: SimonSapin, Assigned: heycam)

Tracking

37 Branch
mozilla43
Points:
---

Firefox Tracking Flags

(firefox43 fixed)

Details

Attachments

(2 attachments)

The attachment is a test case that Firefox currently fails. I just submitted it to the W3C test suite in https://github.com/w3c/csswg-test/pull/852

Custom property values is conceptually sequences of tokens, not strings. Firefox represents them as strings internally, and when substituting variable references with the corresponding value inserts `/**/` between adjacent tokens that would otherwise be re-parsed as a single token.

It relies on the table [1] in the css-syntax spec, but that table has not been updated when the definition of identifier tokens was extended [2] to allow `--` prefixes. This was just fixed [3].

[1] https://drafts.csswg.org/css-syntax/#serialization
[2] http://hg.csswg.org/drafts/rev/ab8b75f1fa88
[3] http://hg.csswg.org/drafts/rev/92d088e07ca2
This new eCSSTokenSerialization_Symbol_Minus case is the same as the earlier eCSSTokenSerialization_Symbol_Hash case, isn’t it?

Also, nice, more tests I didn’t know about. I might steal them for Servo :)
Posted patch patchSplinter Review
Thanks, yes looks like I can join those two cases.

If you want to convert my variables-related mochitests into Web Platform Tests at any point, please be my guest. :-)
Assignee: nobody → cam
Status: NEW → ASSIGNED
Attachment #8659635 - Flags: review?(simon.sapin)
Attachment #8659635 - Flags: review?(simon.sapin) → review+
https://hg.mozilla.org/mozilla-central/rev/5fc62c86d050
Status: ASSIGNED → RESOLVED
Closed: 4 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla43
You need to log in before you can comment on or make changes to this bug.