W3C home > Mailing lists > Public > public-webapps@w3.org > July to September 2012

Re: [selectors-api] RfC: LCWD of Selectors API Level 1; deadline July 19

From: Tab Atkins Jr. <jackalmage@gmail.com>
Date: Mon, 6 Aug 2012 23:27:10 -0700
Message-ID: <CAAWBYDC-nY7SS0Z892HPv9qDit96b0w_qkut+S1z7S-Q+fOPeA@mail.gmail.com>
To: "Kang-Hao (Kenny) Lu" <kanghaol@oupeng.com>
Cc: WebApps Working Group <public-webapps@w3.org>, Lachlan Hunt <lachlan.hunt@lachy.id.au>
On Mon, Aug 6, 2012 at 7:13 PM, Kang-Hao (Kenny) Lu <kanghaol@oupeng.com> wrote:
> (12/08/06 19:25), Lachlan Hunt wrote:
>> On 2012-08-06 13:08, Kang-Hao (Kenny) Lu wrote:
>> I'd rather find a way to address the issue.  I've just been a bit busy
>> with other tasks for the last 2 weeks to look into this.
>>
>> I'd like feedback from implementers about how best to address the issue.
>>  The options I can think of:
>>
>> 1. Disallow all comments within the selector for this API. Throw
>> SyntaxError when they are used.
>> 2. Allow comments, but define that unclosed comments should throw a
>> SyntaxError.
>> 3. Allow comments, define that unclosed comments are silently ignored.
>
> Both 1. and 2. would take some extra code in Gecko, in particular 1. I'd
> note that this is not just about comments. It's about EOF fixing. See
> [1] for other testcases.
>
> [1] http://lists.w3.org/Archives/Public/public-webapps/2012JanMar/0524
>
> (12/08/07 0:20), Tab Atkins Jr. wrote:
>> Officially, 2.1 defines Kenny's example of "html /*" as tokenizing
>> into IDENT WS DELIM DELIM, which is then an invalid selector since
>> nothing recognizes those two delims as part of Selector's syntax.
>
> No, that's IDENT WS(S) BAD_COMMENT

Ah, whoops, indeed.  I forgot that BAD_COMMENT existed.

>> This is compatible with Syntax's treatment, where it's recognized as a
>> comment, but triggers a parse error.
>
> COMMENT is a bit special here and I think you might want to comment on
> other cases in [1].

Hm, kk.

~TJ
Received on Tuesday, 7 August 2012 06:35:17 GMT

This archive was generated by hypermail 2.3.1 : Tuesday, 26 March 2013 18:49:54 GMT