W3C home > Mailing lists > Public > www-style@w3.org > August 2012

Re: [css3-syntax] Thoughts on proposed Syntax module

From: Kang-Hao (Kenny) Lu <kanghaol@oupeng.com>
Date: Wed, 29 Aug 2012 23:58:19 +0800
Message-ID: <503E3C1B.1020209@oupeng.com>
To: "Tab Atkins Jr." <jackalmage@gmail.com>
CC: "L. David Baron" <dbaron@dbaron.org>, WWW Style <www-style@w3.org>
(12/08/29 23:19), Tab Atkins Jr. wrote:
>> I can't reproduce your result in dom viewer with my test case[1] (in
>> both Chrome 21 and 23). Can you save it and share the URL so I can learn
>> what's going on too?
>>
>> [1] http://software.hixie.ch/utilities/js/live-dom-viewer/?saved=1724
> 
> Okay, our parsing is officially retarded.
> 
> Insert a newline immediately before the </style>.  You'll get green.

Ah, it means that WebKit doesn't implement BAD_STRING. See, for example,
this test case[2], where

  "; background: green; }

is tokenized into

  DELIM(;) IDENT(background)

in WebKit instead of

  BAD_STRING("; background: green; })

as required by both CSS 2.1 and the current css3-syntax.

It also means that, when encountering a case like url(a "), WebKit goes
into the string parsing path instead of treating " as a non-) character
like what css3-syntax requires.

Therefore, I disagree with the claim that the current BAD_URI token is
implemented by WebKit. Having said that, I think what css3-syntax says
is not be a bad idea performace-wise and I might favor it eventually.
It's just not matching any implementation as far as I can tell.

[2] http://software.hixie.ch/utilities/js/live-dom-viewer/saved/1725


Cheers,
Kenny
-- 
Web Specialist, Oupeng Browser, Beijing
Try Oupeng: http://www.oupeng.com/
Received on Wednesday, 29 August 2012 15:58:48 GMT

This archive was generated by hypermail 2.3.1 : Tuesday, 26 March 2013 17:20:59 GMT