W3C home > Mailing lists > Public > public-css-archive@w3.org > November 2017

Re: [csswg-drafts] [selectors] querySelector() with quote and/or square bracket missing on right

From: Tab Atkins Jr. via GitHub <sysbot+gh@w3.org>
Date: Mon, 06 Nov 2017 17:22:29 +0000
To: public-css-archive@w3.org
Message-ID: <issue_comment.created-342221311-1509988948-sysbot+gh@w3.org>
Yeah, this is accepted just fine. The grammar doesn't work over text, it works over post-parsing token structures. In particular, `[]`-blocks get "auto-closed" by EOF (or end-of-string, in this case) - you can't tell whether or not there was a `]` character, and in fact it doesn't matter; all that matters is that there *is* a `[]`-block.  ([See the last paragraph in Syntax ch8.](https://drafts.csswg.org/css-syntax/#rule-defs))

In other words, as far as the grammar is concerned, the stuff it's checking over is:


GitHub Notification of comment by tabatkins
Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/1933#issuecomment-342221311 using your GitHub account
Received on Monday, 6 November 2017 17:22:32 UTC

This archive was generated by hypermail 2.3.1 : Monday, 6 November 2017 17:22:33 UTC