- From: Kang-Hao (Kenny) Lu <kennyluck@csail.mit.edu>
- Date: Sat, 07 Apr 2012 07:06:51 +0800
- To: Florian Rivoal <florianr@opera.com>
- CC: WWW Style <www-style@w3.org>
(12/04/07 6:33), Florian Rivoal wrote: > On Thu, 05 Apr 2012 04:07:36 +0200, Tab Atkins Jr. > I still prefer 2d (same thing, except the syntax error is cause at the > expansion of > the variable rather than its definition) for two reasons: > > 1) It deals with this: > ul{ data-foo:!;data-bar:important;} > li{ width: 0 data(foo) data(bar);} Do we seriously want this to work? This is different from what I imagine, but no strong opinion, provided that it is more or equivalently implementable. I think a common opinion earlier was that "!important" is not part of the value. > 2) you will have to parse the result of the expansion anyway, so it is a > good time to detect syntax error. At the data-property definition stage, > only lexing is needed, not parsing (except for the 2 last tokens, to see > if they are "!" and "important"), which makes it at less natural place > to do syntax checks. This seems like a valid argument only if the implementation has clear boundary between the lexing and parsing. I would rather hope we exclude more DELIM at the data-property definition stage so that authors don't get too creative and ask why the following doesn't work: div::before{ data-hash: # ; color: data(hash)ffffff ; } when the debugging window shows that data-hash is inherited. It's potentially harder to explain that HASH is a single token. Cheers, Kenny
Received on Friday, 6 April 2012 23:07:19 UTC