- From: Boris Zbarsky <bzbarsky@MIT.EDU>
- Date: Thu, 21 Jan 2010 11:18:56 -0500
- To: Bert Bos <bert@w3.org>
- CC: public-webapps@w3.org, "www-style@w3.org" <www-style@w3.org>
On 1/21/10 11:11 AM, Bert Bos wrote:
> Here are some examples of relations that always hold. (Assume e is an
> element != NULL.)
>
> e.querySelector("*") == e.querySelector(":root")
Not unless we've recently redefined :root. Can you point me to the
place where that happened?
> e.querySelector("*") == e
Nope. querySelector on an element can only return descendants of the
element. In fact, e.querySelector("*") will return the element's first
element child, if any.
> e.querySelector(":root + *") == NULL
> e.querySelector(":root:first-child") == NULL
Agreed, because as currently defined :root will not match anything in
the subtree rooted at |e|, ever.
> e.querySelector("* *") == e.querySelector(":root> :first-child")
> e.querySelector(":odd") == e.querySelector(":root> :first-child")
Again, not as :root is currently defined.
-Boris
Received on Thursday, 21 January 2010 16:19:32 UTC