W3C home > Mailing lists > Public > www-style@w3.org > March 2011

Re: [CSS2.1] escapes, characters and parsing

From: Bjoern Hoehrmann <derhoermi@gmx.net>
Date: Sun, 27 Mar 2011 01:40:51 +0100
To: Peter Moulder <peter.moulder@monash.edu>
Cc: www-style@w3.org
Message-ID: <9p0to6h2plvsphjenfklbe8d0ugfn564h4@hive.bjoern.hoehrmann.de>
* Peter Moulder wrote:
>On Fri, Mar 25, 2011 at 07:59:07AM +0100, Bjoern Hoehrmann wrote:
>> The ["\2a"] selectors would match elements with node name `*`.
>That's what I would expect to happen, but if WebKit or any other UA
>treats it as universal selector, then I can't say that the spec is
>completely clear about it.

Well, there is no reason to treat `\2a` differently from `\*` as both
are IDENT tokens identifying the same identifier, and there is no reason
to treat `\*` the same as `*` as the backslash is supposed to remove any
special meaning the `*` may have and because there would otherwise be no
way to match an element named `*` even though you can match pretty much
every other name.

Drawing attention to things that are obvious and common sense can quite
often lead to more confusion than was supposed to be mitigated; CSS 2.0
for instance has "Keywords must not be placed between quotes" which had
some people believe that keywords must not be placed between quotes even
though obviously you can place keywords between quotes, they'd just no
longer be keywords (unless you escape the marks...).

The place for such clarifications is the test suite. As "escaped special
character" is among the most obvious test cases, I would expect this to
be covered there already (be that WebKit's or W3C's or whoever's).
Björn Höhrmann · mailto:bjoern@hoehrmann.de · http://bjoern.hoehrmann.de
Am Badedeich 7 · Telefon: +49(0)160/4415681 · http://www.bjoernsworld.de
25899 Dagebüll · PGP Pub. KeyID: 0xA4357E78 · http://www.websitedev.de/ 
Received on Sunday, 27 March 2011 00:41:22 UTC

This archive was generated by hypermail 2.3.1 : Monday, 2 May 2016 14:38:44 UTC